From 90cffbc8aed533a77667a5ee66c3727cb5237b26 Mon Sep 17 00:00:00 2001 From: aws-sdk-go-automation <43143561+aws-sdk-go-automation@users.noreply.github.com> Date: Thu, 21 Mar 2024 14:26:03 -0400 Subject: [PATCH] Release v1.51.5 (2024-03-21) (#5204) Release v1.51.5 (2024-03-21) === ### Service Client Updates * `service/codeartifact`: Updates service API, documentation, and paginators --- CHANGELOG.md | 6 + aws/version.go | 2 +- .../apis/codeartifact/2018-09-22/api-2.json | 697 +- .../apis/codeartifact/2018-09-22/docs-2.json | 395 +- .../2018-09-22/endpoint-rule-set-1.json | 40 +- .../codeartifact/2018-09-22/paginators-1.json | 24 + service/codeartifact/api.go | 9544 +++++++++++------ .../codeartifactiface/interface.go | 52 + service/codeartifact/doc.go | 55 +- 9 files changed, 7647 insertions(+), 3168 deletions(-) diff --git a/CHANGELOG.md b/CHANGELOG.md index 15bb632b067..e9baae1c99e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,9 @@ +Release v1.51.5 (2024-03-21) +=== + +### Service Client Updates +* `service/codeartifact`: Updates service API, documentation, and paginators + Release v1.51.4 (2024-03-20) === diff --git a/aws/version.go b/aws/version.go index 3dee7bac5b0..d0276e7a2d6 100644 --- a/aws/version.go +++ b/aws/version.go @@ -5,4 +5,4 @@ package aws const SDKName = "aws-sdk-go" // SDKVersion is the version of this SDK -const SDKVersion = "1.51.4" +const SDKVersion = "1.51.5" diff --git a/models/apis/codeartifact/2018-09-22/api-2.json b/models/apis/codeartifact/2018-09-22/api-2.json index be8f8362e27..878505a3b64 100644 --- a/models/apis/codeartifact/2018-09-22/api-2.json +++ b/models/apis/codeartifact/2018-09-22/api-2.json @@ -66,6 +66,24 @@ {"shape":"ValidationException"} ] }, + "CreatePackageGroup":{ + "name":"CreatePackageGroup", + "http":{ + "method":"POST", + "requestUri":"/v1/package-group" + }, + "input":{"shape":"CreatePackageGroupRequest"}, + "output":{"shape":"CreatePackageGroupResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"ConflictException"}, + {"shape":"InternalServerException"}, + {"shape":"ServiceQuotaExceededException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "CreateRepository":{ "name":"CreateRepository", "http":{ @@ -134,6 +152,25 @@ {"shape":"ValidationException"} ] }, + "DeletePackageGroup":{ + "name":"DeletePackageGroup", + "http":{ + "method":"DELETE", + "requestUri":"/v1/package-group" + }, + "input":{"shape":"DeletePackageGroupRequest"}, + "output":{"shape":"DeletePackageGroupResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"ConflictException"}, + {"shape":"InternalServerException"}, + {"shape":"ServiceQuotaExceededException"}, + {"shape":"ResourceNotFoundException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"} + ], + "idempotent":true + }, "DeletePackageVersions":{ "name":"DeletePackageVersions", "http":{ @@ -217,6 +254,22 @@ {"shape":"ValidationException"} ] }, + "DescribePackageGroup":{ + "name":"DescribePackageGroup", + "http":{ + "method":"GET", + "requestUri":"/v1/package-group" + }, + "input":{"shape":"DescribePackageGroupRequest"}, + "output":{"shape":"DescribePackageGroupResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"InternalServerException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "DescribePackageVersion":{ "name":"DescribePackageVersion", "http":{ @@ -285,6 +338,21 @@ {"shape":"ValidationException"} ] }, + "GetAssociatedPackageGroup":{ + "name":"GetAssociatedPackageGroup", + "http":{ + "method":"GET", + "requestUri":"/v1/get-associated-package-group" + }, + "input":{"shape":"GetAssociatedPackageGroupRequest"}, + "output":{"shape":"GetAssociatedPackageGroupResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"InternalServerException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "GetAuthorizationToken":{ "name":"GetAuthorizationToken", "http":{ @@ -382,6 +450,38 @@ {"shape":"ValidationException"} ] }, + "ListAllowedRepositoriesForGroup":{ + "name":"ListAllowedRepositoriesForGroup", + "http":{ + "method":"GET", + "requestUri":"/v1/package-group-allowed-repositories" + }, + "input":{"shape":"ListAllowedRepositoriesForGroupRequest"}, + "output":{"shape":"ListAllowedRepositoriesForGroupResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"InternalServerException"}, + {"shape":"ServiceQuotaExceededException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ] + }, + "ListAssociatedPackages":{ + "name":"ListAssociatedPackages", + "http":{ + "method":"GET", + "requestUri":"/v1/list-associated-packages" + }, + "input":{"shape":"ListAssociatedPackagesRequest"}, + "output":{"shape":"ListAssociatedPackagesResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"InternalServerException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "ListDomains":{ "name":"ListDomains", "http":{ @@ -397,6 +497,22 @@ {"shape":"ValidationException"} ] }, + "ListPackageGroups":{ + "name":"ListPackageGroups", + "http":{ + "method":"POST", + "requestUri":"/v1/package-groups" + }, + "input":{"shape":"ListPackageGroupsRequest"}, + "output":{"shape":"ListPackageGroupsResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"InternalServerException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "ListPackageVersionAssets":{ "name":"ListPackageVersionAssets", "http":{ @@ -492,6 +608,22 @@ {"shape":"ValidationException"} ] }, + "ListSubPackageGroups":{ + "name":"ListSubPackageGroups", + "http":{ + "method":"POST", + "requestUri":"/v1/package-groups/sub-groups" + }, + "input":{"shape":"ListSubPackageGroupsRequest"}, + "output":{"shape":"ListSubPackageGroupsResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"InternalServerException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ] + }, "ListTagsForResource":{ "name":"ListTagsForResource", "http":{ @@ -608,6 +740,42 @@ {"shape":"ValidationException"} ] }, + "UpdatePackageGroup":{ + "name":"UpdatePackageGroup", + "http":{ + "method":"PUT", + "requestUri":"/v1/package-group" + }, + "input":{"shape":"UpdatePackageGroupRequest"}, + "output":{"shape":"UpdatePackageGroupResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"InternalServerException"}, + {"shape":"ServiceQuotaExceededException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ], + "idempotent":true + }, + "UpdatePackageGroupOriginConfiguration":{ + "name":"UpdatePackageGroupOriginConfiguration", + "http":{ + "method":"PUT", + "requestUri":"/v1/package-group-origin-configuration" + }, + "input":{"shape":"UpdatePackageGroupOriginConfigurationRequest"}, + "output":{"shape":"UpdatePackageGroupOriginConfigurationResult"}, + "errors":[ + {"shape":"AccessDeniedException"}, + {"shape":"InternalServerException"}, + {"shape":"ServiceQuotaExceededException"}, + {"shape":"ThrottlingException"}, + {"shape":"ValidationException"}, + {"shape":"ResourceNotFoundException"} + ], + "idempotent":true + }, "UpdatePackageVersionsStatus":{ "name":"UpdatePackageVersionsStatus", "http":{ @@ -744,6 +912,19 @@ "repository":{"shape":"RepositoryDescription"} } }, + "AssociatedPackage":{ + "type":"structure", + "members":{ + "format":{"shape":"PackageFormat"}, + "namespace":{"shape":"PackageNamespace"}, + "package":{"shape":"PackageName"}, + "associationType":{"shape":"PackageGroupAssociationType"} + } + }, + "AssociatedPackageList":{ + "type":"list", + "member":{"shape":"AssociatedPackage"} + }, "AuthorizationTokenDurationSeconds":{ "type":"long", "max":43200, @@ -838,6 +1019,35 @@ "domain":{"shape":"DomainDescription"} } }, + "CreatePackageGroupRequest":{ + "type":"structure", + "required":[ + "domain", + "packageGroup" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "packageGroup":{"shape":"PackageGroupPattern"}, + "contactInfo":{"shape":"PackageGroupContactInfo"}, + "description":{"shape":"Description"}, + "tags":{"shape":"TagList"} + } + }, + "CreatePackageGroupResult":{ + "type":"structure", + "members":{ + "packageGroup":{"shape":"PackageGroupDescription"} + } + }, "CreateRepositoryRequest":{ "type":"structure", "required":[ @@ -920,6 +1130,36 @@ "domain":{"shape":"DomainDescription"} } }, + "DeletePackageGroupRequest":{ + "type":"structure", + "required":[ + "domain", + "packageGroup" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "packageGroup":{ + "shape":"String", + "location":"querystring", + "locationName":"package-group" + } + } + }, + "DeletePackageGroupResult":{ + "type":"structure", + "members":{ + "packageGroup":{"shape":"PackageGroupDescription"} + } + }, "DeletePackageRequest":{ "type":"structure", "required":[ @@ -1105,6 +1345,36 @@ "domain":{"shape":"DomainDescription"} } }, + "DescribePackageGroupRequest":{ + "type":"structure", + "required":[ + "domain", + "packageGroup" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "packageGroup":{ + "shape":"PackageGroupPattern", + "location":"querystring", + "locationName":"package-group" + } + } + }, + "DescribePackageGroupResult":{ + "type":"structure", + "members":{ + "packageGroup":{"shape":"PackageGroupDescription"} + } + }, "DescribePackageRequest":{ "type":"structure", "required":[ @@ -1390,6 +1660,48 @@ "type":"string", "enum":["Available"] }, + "GetAssociatedPackageGroupRequest":{ + "type":"structure", + "required":[ + "domain", + "format", + "package" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "format":{ + "shape":"PackageFormat", + "location":"querystring", + "locationName":"format" + }, + "namespace":{ + "shape":"PackageNamespace", + "location":"querystring", + "locationName":"namespace" + }, + "package":{ + "shape":"PackageName", + "location":"querystring", + "locationName":"package" + } + } + }, + "GetAssociatedPackageGroupResult":{ + "type":"structure", + "members":{ + "packageGroup":{"shape":"PackageGroupDescription"}, + "associationType":{"shape":"PackageGroupAssociationType"} + } + }, "GetAuthorizationTokenRequest":{ "type":"structure", "required":["domain"], @@ -1416,7 +1728,8 @@ "members":{ "authorizationToken":{"shape":"String"}, "expiration":{"shape":"Timestamp"} - } + }, + "sensitive":true }, "GetDomainPermissionsPolicyRequest":{ "type":"structure", @@ -1681,6 +1994,104 @@ "type":"list", "member":{"shape":"LicenseInfo"} }, + "ListAllowedRepositoriesForGroupMaxResults":{ + "type":"integer", + "max":1000, + "min":1 + }, + "ListAllowedRepositoriesForGroupRequest":{ + "type":"structure", + "required":[ + "domain", + "packageGroup", + "originRestrictionType" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "packageGroup":{ + "shape":"PackageGroupPattern", + "location":"querystring", + "locationName":"package-group" + }, + "originRestrictionType":{ + "shape":"PackageGroupOriginRestrictionType", + "location":"querystring", + "locationName":"originRestrictionType" + }, + "maxResults":{ + "shape":"ListAllowedRepositoriesForGroupMaxResults", + "location":"querystring", + "locationName":"max-results" + }, + "nextToken":{ + "shape":"PaginationToken", + "location":"querystring", + "locationName":"next-token" + } + } + }, + "ListAllowedRepositoriesForGroupResult":{ + "type":"structure", + "members":{ + "allowedRepositories":{"shape":"RepositoryNameList"}, + "nextToken":{"shape":"PaginationToken"} + } + }, + "ListAssociatedPackagesRequest":{ + "type":"structure", + "required":[ + "domain", + "packageGroup" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "packageGroup":{ + "shape":"PackageGroupPattern", + "location":"querystring", + "locationName":"package-group" + }, + "maxResults":{ + "shape":"ListPackagesMaxResults", + "location":"querystring", + "locationName":"max-results" + }, + "nextToken":{ + "shape":"PaginationToken", + "location":"querystring", + "locationName":"next-token" + }, + "preview":{ + "shape":"BooleanOptional", + "location":"querystring", + "locationName":"preview" + } + } + }, + "ListAssociatedPackagesResult":{ + "type":"structure", + "members":{ + "packages":{"shape":"AssociatedPackageList"}, + "nextToken":{"shape":"PaginationToken"} + } + }, "ListDomainsMaxResults":{ "type":"integer", "max":1000, @@ -1700,6 +2111,49 @@ "nextToken":{"shape":"PaginationToken"} } }, + "ListPackageGroupsMaxResults":{ + "type":"integer", + "max":1000, + "min":1 + }, + "ListPackageGroupsRequest":{ + "type":"structure", + "required":["domain"], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "maxResults":{ + "shape":"ListPackageGroupsMaxResults", + "location":"querystring", + "locationName":"max-results" + }, + "nextToken":{ + "shape":"PaginationToken", + "location":"querystring", + "locationName":"next-token" + }, + "prefix":{ + "shape":"PackageGroupPatternPrefix", + "location":"querystring", + "locationName":"prefix" + } + } + }, + "ListPackageGroupsResult":{ + "type":"structure", + "members":{ + "packageGroups":{"shape":"PackageGroupSummaryList"}, + "nextToken":{"shape":"PaginationToken"} + } + }, "ListPackageVersionAssetsMaxResults":{ "type":"integer", "max":1000, @@ -2071,6 +2525,47 @@ "nextToken":{"shape":"PaginationToken"} } }, + "ListSubPackageGroupsRequest":{ + "type":"structure", + "required":[ + "domain", + "packageGroup" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "packageGroup":{ + "shape":"PackageGroupPattern", + "location":"querystring", + "locationName":"package-group" + }, + "maxResults":{ + "shape":"ListPackageGroupsMaxResults", + "location":"querystring", + "locationName":"max-results" + }, + "nextToken":{ + "shape":"PaginationToken", + "location":"querystring", + "locationName":"next-token" + } + } + }, + "ListSubPackageGroupsResult":{ + "type":"structure", + "members":{ + "packageGroups":{"shape":"PackageGroupSummaryList"}, + "nextToken":{"shape":"PaginationToken"} + } + }, "ListTagsForResourceRequest":{ "type":"structure", "required":["resourceArn"], @@ -2090,6 +2585,11 @@ }, "Long":{"type":"long"}, "LongOptional":{"type":"long"}, + "OriginRestrictions":{ + "type":"map", + "key":{"shape":"PackageGroupOriginRestrictionType"}, + "value":{"shape":"PackageGroupOriginRestrictionMode"} + }, "PackageDependency":{ "type":"structure", "members":{ @@ -2123,6 +2623,135 @@ "swift" ] }, + "PackageGroupAllowedRepository":{ + "type":"structure", + "members":{ + "repositoryName":{"shape":"RepositoryName"}, + "originRestrictionType":{"shape":"PackageGroupOriginRestrictionType"} + } + }, + "PackageGroupAllowedRepositoryList":{ + "type":"list", + "member":{"shape":"PackageGroupAllowedRepository"} + }, + "PackageGroupAllowedRepositoryUpdate":{ + "type":"map", + "key":{"shape":"PackageGroupAllowedRepositoryUpdateType"}, + "value":{"shape":"RepositoryNameList"} + }, + "PackageGroupAllowedRepositoryUpdateType":{ + "type":"string", + "enum":[ + "ADDED", + "REMOVED" + ] + }, + "PackageGroupAllowedRepositoryUpdates":{ + "type":"map", + "key":{"shape":"PackageGroupOriginRestrictionType"}, + "value":{"shape":"PackageGroupAllowedRepositoryUpdate"} + }, + "PackageGroupAssociationType":{ + "type":"string", + "enum":[ + "STRONG", + "WEAK" + ] + }, + "PackageGroupContactInfo":{ + "type":"string", + "max":1000, + "min":0, + "pattern":"\\P{C}*" + }, + "PackageGroupDescription":{ + "type":"structure", + "members":{ + "arn":{"shape":"Arn"}, + "pattern":{"shape":"PackageGroupPattern"}, + "domainName":{"shape":"DomainName"}, + "domainOwner":{"shape":"AccountId"}, + "createdTime":{"shape":"Timestamp"}, + "contactInfo":{"shape":"PackageGroupContactInfo"}, + "description":{"shape":"Description"}, + "originConfiguration":{"shape":"PackageGroupOriginConfiguration"}, + "parent":{"shape":"PackageGroupReference"} + } + }, + "PackageGroupOriginConfiguration":{ + "type":"structure", + "members":{ + "restrictions":{"shape":"PackageGroupOriginRestrictions"} + } + }, + "PackageGroupOriginRestriction":{ + "type":"structure", + "members":{ + "mode":{"shape":"PackageGroupOriginRestrictionMode"}, + "effectiveMode":{"shape":"PackageGroupOriginRestrictionMode"}, + "inheritedFrom":{"shape":"PackageGroupReference"}, + "repositoriesCount":{"shape":"LongOptional"} + } + }, + "PackageGroupOriginRestrictionMode":{ + "type":"string", + "enum":[ + "ALLOW", + "ALLOW_SPECIFIC_REPOSITORIES", + "BLOCK", + "INHERIT" + ] + }, + "PackageGroupOriginRestrictionType":{ + "type":"string", + "enum":[ + "EXTERNAL_UPSTREAM", + "INTERNAL_UPSTREAM", + "PUBLISH" + ] + }, + "PackageGroupOriginRestrictions":{ + "type":"map", + "key":{"shape":"PackageGroupOriginRestrictionType"}, + "value":{"shape":"PackageGroupOriginRestriction"} + }, + "PackageGroupPattern":{ + "type":"string", + "max":520, + "min":2, + "pattern":"[^\\p{C}\\p{IsWhitespace}]+" + }, + "PackageGroupPatternPrefix":{ + "type":"string", + "max":520, + "min":0, + "pattern":"\\P{C}*" + }, + "PackageGroupReference":{ + "type":"structure", + "members":{ + "arn":{"shape":"Arn"}, + "pattern":{"shape":"PackageGroupPattern"} + } + }, + "PackageGroupSummary":{ + "type":"structure", + "members":{ + "arn":{"shape":"Arn"}, + "pattern":{"shape":"PackageGroupPattern"}, + "domainName":{"shape":"DomainName"}, + "domainOwner":{"shape":"AccountId"}, + "createdTime":{"shape":"Timestamp"}, + "contactInfo":{"shape":"PackageGroupContactInfo"}, + "description":{"shape":"Description"}, + "originConfiguration":{"shape":"PackageGroupOriginConfiguration"}, + "parent":{"shape":"PackageGroupReference"} + } + }, + "PackageGroupSummaryList":{ + "type":"list", + "member":{"shape":"PackageGroupSummary"} + }, "PackageName":{ "type":"string", "max":255, @@ -2505,6 +3134,10 @@ "min":2, "pattern":"[A-Za-z0-9][A-Za-z0-9._\\-]{1,99}" }, + "RepositoryNameList":{ + "type":"list", + "member":{"shape":"RepositoryName"} + }, "RepositorySummary":{ "type":"structure", "members":{ @@ -2676,6 +3309,68 @@ "members":{ } }, + "UpdatePackageGroupOriginConfigurationRequest":{ + "type":"structure", + "required":[ + "domain", + "packageGroup" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "packageGroup":{ + "shape":"PackageGroupPattern", + "location":"querystring", + "locationName":"package-group" + }, + "restrictions":{"shape":"OriginRestrictions"}, + "addAllowedRepositories":{"shape":"PackageGroupAllowedRepositoryList"}, + "removeAllowedRepositories":{"shape":"PackageGroupAllowedRepositoryList"} + } + }, + "UpdatePackageGroupOriginConfigurationResult":{ + "type":"structure", + "members":{ + "packageGroup":{"shape":"PackageGroupDescription"}, + "allowedRepositoryUpdates":{"shape":"PackageGroupAllowedRepositoryUpdates"} + } + }, + "UpdatePackageGroupRequest":{ + "type":"structure", + "required":[ + "domain", + "packageGroup" + ], + "members":{ + "domain":{ + "shape":"DomainName", + "location":"querystring", + "locationName":"domain" + }, + "domainOwner":{ + "shape":"AccountId", + "location":"querystring", + "locationName":"domain-owner" + }, + "packageGroup":{"shape":"PackageGroupPattern"}, + "contactInfo":{"shape":"PackageGroupContactInfo"}, + "description":{"shape":"Description"} + } + }, + "UpdatePackageGroupResult":{ + "type":"structure", + "members":{ + "packageGroup":{"shape":"PackageGroupDescription"} + } + }, "UpdatePackageVersionsStatusRequest":{ "type":"structure", "required":[ diff --git a/models/apis/codeartifact/2018-09-22/docs-2.json b/models/apis/codeartifact/2018-09-22/docs-2.json index 10009e07886..4038638d8cf 100644 --- a/models/apis/codeartifact/2018-09-22/docs-2.json +++ b/models/apis/codeartifact/2018-09-22/docs-2.json @@ -1,36 +1,44 @@ { "version": "2.0", - "service": "

CodeArtifact is a fully managed artifact repository compatible with language-native package managers and build tools such as npm, Apache Maven, pip, and dotnet. You can use CodeArtifact to share packages with development teams and pull packages. Packages can be pulled from both public and CodeArtifact repositories. You can also create an upstream relationship between a CodeArtifact repository and another repository, which effectively merges their contents from the point of view of a package manager client.

CodeArtifact Components

Use the information in this guide to help you work with the following CodeArtifact components:

CodeArtifact supports these operations:

", + "service": "

CodeArtifact is a fully managed artifact repository compatible with language-native package managers and build tools such as npm, Apache Maven, pip, and dotnet. You can use CodeArtifact to share packages with development teams and pull packages. Packages can be pulled from both public and CodeArtifact repositories. You can also create an upstream relationship between a CodeArtifact repository and another repository, which effectively merges their contents from the point of view of a package manager client.

CodeArtifact concepts

CodeArtifact supported API operations

", "operations": { "AssociateExternalConnection": "

Adds an existing external connection to a repository. One external connection is allowed per repository.

A repository can have one or more upstream repositories, or an external connection.

", "CopyPackageVersions": "

Copies package versions from one repository to another repository in the same domain.

You must specify versions or versionRevisions. You cannot specify both.

", "CreateDomain": "

Creates a domain. CodeArtifact domains make it easier to manage multiple repositories across an organization. You can use a domain to apply permissions across many repositories owned by different Amazon Web Services accounts. An asset is stored only once in a domain, even if it's in multiple repositories.

Although you can have multiple domains, we recommend a single production domain that contains all published artifacts so that your development teams can find and share packages. You can use a second pre-production domain to test changes to the production domain configuration.

", + "CreatePackageGroup": "

Creates a package group. For more information about creating package groups, including example CLI commands, see Create a package group in the CodeArtifact User Guide.

", "CreateRepository": "

Creates a repository.

", "DeleteDomain": "

Deletes a domain. You cannot delete a domain that contains repositories. If you want to delete a domain with repositories, first delete its repositories.

", "DeleteDomainPermissionsPolicy": "

Deletes the resource policy set on a domain.

", "DeletePackage": "

Deletes a package and all associated package versions. A deleted package cannot be restored. To delete one or more package versions, use the DeletePackageVersions API.

", + "DeletePackageGroup": "

Deletes a package group. Deleting a package group does not delete packages or package versions associated with the package group. When a package group is deleted, the direct child package groups will become children of the package group's direct parent package group. Therefore, if any of the child groups are inheriting any settings from the parent, those settings could change.

", "DeletePackageVersions": "

Deletes one or more versions of a package. A deleted package version cannot be restored in your repository. If you want to remove a package version from your repository and be able to restore it later, set its status to Archived. Archived packages cannot be downloaded from a repository and don't show up with list package APIs (for example, ListPackageVersions), but you can restore them using UpdatePackageVersionsStatus.

", "DeleteRepository": "

Deletes a repository.

", "DeleteRepositoryPermissionsPolicy": "

Deletes the resource policy that is set on a repository. After a resource policy is deleted, the permissions allowed and denied by the deleted policy are removed. The effect of deleting a resource policy might not be immediate.

Use DeleteRepositoryPermissionsPolicy with caution. After a policy is deleted, Amazon Web Services users, roles, and accounts lose permissions to perform the repository actions granted by the deleted policy.

", "DescribeDomain": "

Returns a DomainDescription object that contains information about the requested domain.

", "DescribePackage": "

Returns a PackageDescription object that contains information about the requested package.

", + "DescribePackageGroup": "

Returns a PackageGroupDescription object that contains information about the requested package group.

", "DescribePackageVersion": "

Returns a PackageVersionDescription object that contains information about the requested package version.

", "DescribeRepository": "

Returns a RepositoryDescription object that contains detailed information about the requested repository.

", "DisassociateExternalConnection": "

Removes an existing external connection from a repository.

", "DisposePackageVersions": "

Deletes the assets in package versions and sets the package versions' status to Disposed. A disposed package version cannot be restored in your repository because its assets are deleted.

To view all disposed package versions in a repository, use ListPackageVersions and set the status parameter to Disposed.

To view information about a disposed package version, use DescribePackageVersion.

", + "GetAssociatedPackageGroup": "

Returns the most closely associated package group to the specified package. This API does not require that the package exist in any repository in the domain. As such, GetAssociatedPackageGroup can be used to see which package group's origin configuration applies to a package before that package is in a repository. This can be helpful to check if public packages are blocked without ingesting them.

For information package group association and matching, see Package group definition syntax and matching behavior in the CodeArtifact User Guide.

", "GetAuthorizationToken": "

Generates a temporary authorization token for accessing repositories in the domain. This API requires the codeartifact:GetAuthorizationToken and sts:GetServiceBearerToken permissions. For more information about authorization tokens, see CodeArtifact authentication and tokens.

CodeArtifact authorization tokens are valid for a period of 12 hours when created with the login command. You can call login periodically to refresh the token. When you create an authorization token with the GetAuthorizationToken API, you can set a custom authorization period, up to a maximum of 12 hours, with the durationSeconds parameter.

The authorization period begins after login or GetAuthorizationToken is called. If login or GetAuthorizationToken is called while assuming a role, the token lifetime is independent of the maximum session duration of the role. For example, if you call sts assume-role and specify a session duration of 15 minutes, then generate a CodeArtifact authorization token, the token will be valid for the full authorization period even though this is longer than the 15-minute session duration.

See Using IAM Roles for more information on controlling session duration.

", "GetDomainPermissionsPolicy": "

Returns the resource policy attached to the specified domain.

The policy is a resource-based policy, not an identity-based policy. For more information, see Identity-based policies and resource-based policies in the IAM User Guide.

", "GetPackageVersionAsset": "

Returns an asset (or file) that is in a package. For example, for a Maven package version, use GetPackageVersionAsset to download a JAR file, a POM file, or any other assets in the package version.

", "GetPackageVersionReadme": "

Gets the readme file or descriptive text for a package version.

The returned text might contain formatting. For example, it might contain formatting for Markdown or reStructuredText.

", - "GetRepositoryEndpoint": "

Returns the endpoint of a repository for a specific package format. A repository has one endpoint for each package format:

", + "GetRepositoryEndpoint": "

Returns the endpoint of a repository for a specific package format. A repository has one endpoint for each package format:

", "GetRepositoryPermissionsPolicy": "

Returns the resource policy that is set on a repository.

", + "ListAllowedRepositoriesForGroup": "

Lists the repositories in the added repositories list of the specified restriction type for a package group. For more information about restriction types and added repository lists, see Package group origin controls in the CodeArtifact User Guide.

", + "ListAssociatedPackages": "

Returns a list of packages associated with the requested package group. For information package group association and matching, see Package group definition syntax and matching behavior in the CodeArtifact User Guide.

", "ListDomains": "

Returns a list of DomainSummary objects for all domains owned by the Amazon Web Services account that makes this call. Each returned DomainSummary object contains information about a domain.

", + "ListPackageGroups": "

Returns a list of package groups in the requested domain.

", "ListPackageVersionAssets": "

Returns a list of AssetSummary objects for assets in a package version.

", "ListPackageVersionDependencies": "

Returns the direct dependencies for a package version. The dependencies are returned as PackageDependency objects. CodeArtifact extracts the dependencies for a package version from the metadata file for the package format (for example, the package.json file for npm packages and the pom.xml file for Maven). Any package version dependencies that are not listed in the configuration file are not returned.

", "ListPackageVersions": "

Returns a list of PackageVersionSummary objects for package versions in a repository that match the request parameters. Package versions of all statuses will be returned by default when calling list-package-versions with no --status parameter.

", "ListPackages": "

Returns a list of PackageSummary objects for packages in a repository that match the request parameters.

", "ListRepositories": "

Returns a list of RepositorySummary objects. Each RepositorySummary contains information about a repository in the specified Amazon Web Services account and that matches the input parameters.

", "ListRepositoriesInDomain": "

Returns a list of RepositorySummary objects. Each RepositorySummary contains information about a repository in the specified domain and that matches the input parameters.

", + "ListSubPackageGroups": "

Returns a list of direct children of the specified package group.

For information package group hierarchy, see Package group definition syntax and matching behavior in the CodeArtifact User Guide.

", "ListTagsForResource": "

Gets information about Amazon Web Services tags for a specified Amazon Resource Name (ARN) in CodeArtifact.

", "PublishPackageVersion": "

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.

", "PutDomainPermissionsPolicy": "

Sets a resource policy on a domain that specifies permissions to access it.

When you call PutDomainPermissionsPolicy, the resource policy on the domain is ignored when evaluting permissions. This ensures that the owner of a domain cannot lock themselves out of the domain, which would prevent them from being able to update the resource policy.

", @@ -38,6 +46,8 @@ "PutRepositoryPermissionsPolicy": "

Sets the resource policy on a repository that specifies permissions to access it.

When you call PutRepositoryPermissionsPolicy, the resource policy on the repository is ignored when evaluting permissions. This ensures that the owner of a repository cannot lock themselves out of the repository, which would prevent them from being able to update the resource policy.

", "TagResource": "

Adds or updates tags for a resource in CodeArtifact.

", "UntagResource": "

Removes tags from a resource in CodeArtifact.

", + "UpdatePackageGroup": "

Updates a package group. This API cannot be used to update a package group's origin configuration or pattern. To update a package group's origin configuration, use UpdatePackageGroupOriginConfiguration.

", + "UpdatePackageGroupOriginConfiguration": "

Updates the package origin configuration for a package group.

The package origin configuration determines how new versions of a package can be added to a repository. You can allow or block direct publishing of new package versions, or ingestion and retaining of new package versions from an external connection or upstream source. For more information about package group origin controls and configuration, see Package group origin controls in the CodeArtifact User Guide.

", "UpdatePackageVersionsStatus": "

Updates the status of one or more versions of a package. Using UpdatePackageVersionsStatus, you can update the status of package versions to Archived, Published, or Unlisted. To set the status of a package version to Disposed, use DisposePackageVersions.

", "UpdateRepository": "

Update the properties of a repository.

" }, @@ -52,14 +62,17 @@ "refs": { "AssociateExternalConnectionRequest$domainOwner": "

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

", "CopyPackageVersionsRequest$domainOwner": "

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

", + "CreatePackageGroupRequest$domainOwner": "

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

", "CreateRepositoryRequest$domainOwner": "

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

", "DeleteDomainPermissionsPolicyRequest$domainOwner": "

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

", "DeleteDomainRequest$domainOwner": "

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

", + "DeletePackageGroupRequest$domainOwner": "

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

", "DeletePackageRequest$domainOwner": "

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

", "DeletePackageVersionsRequest$domainOwner": "

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

", "DeleteRepositoryPermissionsPolicyRequest$domainOwner": "

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

", "DeleteRepositoryRequest$domainOwner": "

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

", "DescribeDomainRequest$domainOwner": "

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

", + "DescribePackageGroupRequest$domainOwner": "

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

", "DescribePackageRequest$domainOwner": "

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

", "DescribePackageVersionRequest$domainOwner": "

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

", "DescribeRepositoryRequest$domainOwner": "

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

", @@ -67,18 +80,25 @@ "DisposePackageVersionsRequest$domainOwner": "

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

", "DomainDescription$owner": "

The Amazon Web Services account ID that owns the domain.

", "DomainSummary$owner": "

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

", + "GetAssociatedPackageGroupRequest$domainOwner": "

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

", "GetAuthorizationTokenRequest$domainOwner": "

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

", "GetDomainPermissionsPolicyRequest$domainOwner": "

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

", "GetPackageVersionAssetRequest$domainOwner": "

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

", "GetPackageVersionReadmeRequest$domainOwner": "

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

", "GetRepositoryEndpointRequest$domainOwner": "

The 12-digit account number of the Amazon Web Services account that owns the domain that contains the repository. It does not include dashes or spaces.

", "GetRepositoryPermissionsPolicyRequest$domainOwner": "

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

", + "ListAllowedRepositoriesForGroupRequest$domainOwner": "

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

", + "ListAssociatedPackagesRequest$domainOwner": "

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

", + "ListPackageGroupsRequest$domainOwner": "

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

", "ListPackageVersionAssetsRequest$domainOwner": "

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

", "ListPackageVersionDependenciesRequest$domainOwner": "

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

", "ListPackageVersionsRequest$domainOwner": "

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

", "ListPackagesRequest$domainOwner": "

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

", "ListRepositoriesInDomainRequest$domainOwner": "

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

", "ListRepositoriesInDomainRequest$administratorAccount": "

Filter the list of repositories to only include those that are managed by the Amazon Web Services account ID.

", + "ListSubPackageGroupsRequest$domainOwner": "

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

", + "PackageGroupDescription$domainOwner": "

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

", + "PackageGroupSummary$domainOwner": "

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

", "PublishPackageVersionRequest$domainOwner": "

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

", "PutDomainPermissionsPolicyRequest$domainOwner": "

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

", "PutPackageOriginConfigurationRequest$domainOwner": "

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

", @@ -87,6 +107,8 @@ "RepositoryDescription$domainOwner": "

The 12-digit account number of the Amazon Web Services account that owns the domain that contains the repository. It does not include dashes or spaces.

", "RepositorySummary$administratorAccount": "

The Amazon Web Services account ID that manages the repository.

", "RepositorySummary$domainOwner": "

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

", + "UpdatePackageGroupOriginConfigurationRequest$domainOwner": "

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

", + "UpdatePackageGroupRequest$domainOwner": "

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

", "UpdatePackageVersionsStatusRequest$domainOwner": "

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

", "UpdateRepositoryRequest$domainOwner": "

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

" } @@ -115,6 +137,9 @@ "DomainSummary$arn": "

The ARN of the domain.

", "DomainSummary$encryptionKey": "

The key used to encrypt the domain.

", "ListTagsForResourceRequest$resourceArn": "

The Amazon Resource Name (ARN) of the resource to get tags for.

", + "PackageGroupDescription$arn": "

The ARN of the package group.

", + "PackageGroupReference$arn": "

The ARN of the package group.

", + "PackageGroupSummary$arn": "

The ARN of the package group.

", "RepositoryDescription$arn": "

The Amazon Resource Name (ARN) of the repository.

", "RepositorySummary$arn": "

The ARN of the repository.

", "ResourcePolicy$resourceArn": "

The ARN of the resource associated with the resource policy

", @@ -167,6 +192,18 @@ "refs": { } }, + "AssociatedPackage": { + "base": "

A package associated with a package group.

", + "refs": { + "AssociatedPackageList$member": null + } + }, + "AssociatedPackageList": { + "base": null, + "refs": { + "ListAssociatedPackagesResult$packages": "

The list of packages associated with the requested package group.

" + } + }, "AuthorizationTokenDurationSeconds": { "base": null, "refs": { @@ -178,6 +215,7 @@ "refs": { "CopyPackageVersionsRequest$allowOverwrite": "

Set to true to overwrite a package version that already exists in the destination repository. If set to false and the package version already exists in the destination repository, the package version is returned in the failedVersions field of the response with an ALREADY_EXISTS error code.

", "CopyPackageVersionsRequest$includeFromUpstream": "

Set to true to copy packages from repositories that are upstream from the source repository to the destination repository. The default setting is false. For more information, see Working with upstream repositories.

", + "ListAssociatedPackagesRequest$preview": "

When this flag is included, ListAssociatedPackages will return a list of packages that would be associated with a package group, even if it does not exist.

", "PublishPackageVersionRequest$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

" } }, @@ -206,6 +244,16 @@ "refs": { } }, + "CreatePackageGroupRequest": { + "base": null, + "refs": { + } + }, + "CreatePackageGroupResult": { + "base": null, + "refs": { + } + }, "CreateRepositoryRequest": { "base": null, "refs": { @@ -236,6 +284,16 @@ "refs": { } }, + "DeletePackageGroupRequest": { + "base": null, + "refs": { + } + }, + "DeletePackageGroupResult": { + "base": null, + "refs": { + } + }, "DeletePackageRequest": { "base": null, "refs": { @@ -286,6 +344,16 @@ "refs": { } }, + "DescribePackageGroupRequest": { + "base": null, + "refs": { + } + }, + "DescribePackageGroupResult": { + "base": null, + "refs": { + } + }, "DescribePackageRequest": { "base": null, "refs": { @@ -319,9 +387,13 @@ "Description": { "base": null, "refs": { + "CreatePackageGroupRequest$description": "

A description of the package group.

", "CreateRepositoryRequest$description": "

A description of the created repository.

", + "PackageGroupDescription$description": "

The description of the package group.

", + "PackageGroupSummary$description": "

The description of the package group.

", "RepositoryDescription$description": "

A text description of the repository.

", "RepositorySummary$description": "

The description of the repository.

", + "UpdatePackageGroupRequest$description": "

The description you want to update the requested package group with.

", "UpdateRepositoryRequest$description": "

An updated repository description.

" } }, @@ -354,7 +426,7 @@ } }, "DomainEntryPoint": { - "base": "

Information about how a package originally entered the CodeArtifact domain. For packages published directly to CodeArtifact, the entry point is the repository it was published to. For packages ingested from an external repository, the entry point is the external connection that it was ingested from. An external connection is a CodeArtifact repository that is connected to an external repository such as the npm registry or NuGet gallery.

", + "base": "

Information about how a package originally entered the CodeArtifact domain. For packages published directly to CodeArtifact, the entry point is the repository it was published to. For packages ingested from an external repository, the entry point is the external connection that it was ingested from. An external connection is a CodeArtifact repository that is connected to an external repository such as the npm registry or NuGet gallery.

If a package version exists in a repository and is updated, for example if a package of the same version is added with additional assets, the package version's DomainEntryPoint will not change from the original package version's value.

", "refs": { "PackageVersionOrigin$domainEntryPoint": "

A DomainEntryPoint object that contains information about from which repository or external connection the package version was added to the domain.

" } @@ -365,14 +437,17 @@ "AssociateExternalConnectionRequest$domain": "

The name of the domain that contains the repository.

", "CopyPackageVersionsRequest$domain": "

The name of the domain that contains the source and destination repositories.

", "CreateDomainRequest$domain": "

The name of the domain to create. All domain names in an Amazon Web Services Region that are in the same Amazon Web Services account must be unique. The domain name is used as the prefix in DNS hostnames. Do not use sensitive information in a domain name because it is publicly discoverable.

", + "CreatePackageGroupRequest$domain": "

The name of the domain in which you want to create a package group.

", "CreateRepositoryRequest$domain": "

The name of the domain that contains the created repository.

", "DeleteDomainPermissionsPolicyRequest$domain": "

The name of the domain associated with the resource policy to be deleted.

", "DeleteDomainRequest$domain": "

The name of the domain to delete.

", + "DeletePackageGroupRequest$domain": "

The domain that contains the package group to be deleted.

", "DeletePackageRequest$domain": "

The name of the domain that contains the package to delete.

", "DeletePackageVersionsRequest$domain": "

The name of the domain that contains the package to delete.

", "DeleteRepositoryPermissionsPolicyRequest$domain": "

The name of the domain that contains the repository associated with the resource policy to be deleted.

", "DeleteRepositoryRequest$domain": "

The name of the domain that contains the repository to delete.

", "DescribeDomainRequest$domain": "

A string that specifies the name of the requested domain.

", + "DescribePackageGroupRequest$domain": "

The name of the domain that contains the package group.

", "DescribePackageRequest$domain": "

The name of the domain that contains the repository that contains the package.

", "DescribePackageVersionRequest$domain": "

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

", "DescribeRepositoryRequest$domain": "

The name of the domain that contains the repository to describe.

", @@ -380,23 +455,32 @@ "DisposePackageVersionsRequest$domain": "

The name of the domain that contains the repository you want to dispose.

", "DomainDescription$name": "

The name of the domain.

", "DomainSummary$name": "

The name of the domain.

", + "GetAssociatedPackageGroupRequest$domain": "

The name of the domain that contains the package from which to get the associated package group.

", "GetAuthorizationTokenRequest$domain": "

The name of the domain that is in scope for the generated authorization token.

", "GetDomainPermissionsPolicyRequest$domain": "

The name of the domain to which the resource policy is attached.

", "GetPackageVersionAssetRequest$domain": "

The name of the domain that contains the repository that contains the package version with the requested asset.

", "GetPackageVersionReadmeRequest$domain": "

The name of the domain that contains the repository that contains the package version with the requested readme file.

", "GetRepositoryEndpointRequest$domain": "

The name of the domain that contains the repository.

", "GetRepositoryPermissionsPolicyRequest$domain": "

The name of the domain containing the repository whose associated resource policy is to be retrieved.

", + "ListAllowedRepositoriesForGroupRequest$domain": "

The name of the domain that contains the package group from which to list allowed repositories.

", + "ListAssociatedPackagesRequest$domain": "

The name of the domain that contains the package group from which to list associated packages.

", + "ListPackageGroupsRequest$domain": "

The domain for which you want to list package groups.

", "ListPackageVersionAssetsRequest$domain": "

The name of the domain that contains the repository associated with the package version assets.

", "ListPackageVersionDependenciesRequest$domain": "

The name of the domain that contains the repository that contains the requested package version dependencies.

", "ListPackageVersionsRequest$domain": "

The name of the domain that contains the repository that contains the requested package versions.

", "ListPackagesRequest$domain": "

The name of the domain that contains the repository that contains the requested packages.

", "ListRepositoriesInDomainRequest$domain": "

The name of the domain that contains the returned list of repositories.

", + "ListSubPackageGroupsRequest$domain": "

The name of the domain which contains the package group from which to list sub package groups.

", + "PackageGroupDescription$domainName": "

The name of the domain that contains the package group.

", + "PackageGroupSummary$domainName": "

The domain that contains the package group.

", "PublishPackageVersionRequest$domain": "

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

", "PutDomainPermissionsPolicyRequest$domain": "

The name of the domain on which to set the resource policy.

", "PutPackageOriginConfigurationRequest$domain": "

The name of the domain that contains the repository that contains the package.

", "PutRepositoryPermissionsPolicyRequest$domain": "

The name of the domain containing the repository to set the resource policy on.

", "RepositoryDescription$domainName": "

The name of the domain that contains the repository.

", "RepositorySummary$domainName": "

The name of the domain that contains the repository.

", + "UpdatePackageGroupOriginConfigurationRequest$domain": "

The name of the domain which contains the package group for which to update the origin configuration.

", + "UpdatePackageGroupRequest$domain": "

The name of the domain which contains the package group to be updated.

", "UpdatePackageVersionsStatusRequest$domain": "

The name of the domain that contains the repository that contains the package versions with a status to be updated.

", "UpdateRepositoryRequest$domain": "

The name of the domain associated with the repository to update.

" } @@ -441,6 +525,16 @@ "RepositoryExternalConnectionInfo$status": "

The status of the external connection of a repository. There is one valid value, Available.

" } }, + "GetAssociatedPackageGroupRequest": { + "base": null, + "refs": { + } + }, + "GetAssociatedPackageGroupResult": { + "base": null, + "refs": { + } + }, "GetAuthorizationTokenRequest": { "base": null, "refs": { @@ -536,6 +630,32 @@ "PackageVersionDescription$licenses": "

Information about licenses associated with the package version.

" } }, + "ListAllowedRepositoriesForGroupMaxResults": { + "base": null, + "refs": { + "ListAllowedRepositoriesForGroupRequest$maxResults": "

The maximum number of results to return per page.

" + } + }, + "ListAllowedRepositoriesForGroupRequest": { + "base": null, + "refs": { + } + }, + "ListAllowedRepositoriesForGroupResult": { + "base": null, + "refs": { + } + }, + "ListAssociatedPackagesRequest": { + "base": null, + "refs": { + } + }, + "ListAssociatedPackagesResult": { + "base": null, + "refs": { + } + }, "ListDomainsMaxResults": { "base": null, "refs": { @@ -552,6 +672,23 @@ "refs": { } }, + "ListPackageGroupsMaxResults": { + "base": null, + "refs": { + "ListPackageGroupsRequest$maxResults": "

The maximum number of results to return per page.

", + "ListSubPackageGroupsRequest$maxResults": "

The maximum number of results to return per page.

" + } + }, + "ListPackageGroupsRequest": { + "base": null, + "refs": { + } + }, + "ListPackageGroupsResult": { + "base": null, + "refs": { + } + }, "ListPackageVersionAssetsMaxResults": { "base": null, "refs": { @@ -597,6 +734,7 @@ "ListPackagesMaxResults": { "base": null, "refs": { + "ListAssociatedPackagesRequest$maxResults": "

The maximum number of results to return per page.

", "ListPackagesRequest$maxResults": "

The maximum number of results to return per page.

" } }, @@ -642,6 +780,16 @@ "refs": { } }, + "ListSubPackageGroupsRequest": { + "base": null, + "refs": { + } + }, + "ListSubPackageGroupsResult": { + "base": null, + "refs": { + } + }, "ListTagsForResourceRequest": { "base": null, "refs": { @@ -661,7 +809,14 @@ "LongOptional": { "base": null, "refs": { - "AssetSummary$size": "

The size of the asset.

" + "AssetSummary$size": "

The size of the asset.

", + "PackageGroupOriginRestriction$repositoriesCount": "

The number of repositories in the allowed repository list.

" + } + }, + "OriginRestrictions": { + "base": null, + "refs": { + "UpdatePackageGroupOriginConfigurationRequest$restrictions": "

The origin configuration settings that determine how package versions can enter repositories.

" } }, "PackageDependency": { @@ -685,12 +840,14 @@ "PackageFormat": { "base": null, "refs": { + "AssociatedPackage$format": "

A format that specifies the type of the associated package.

", "CopyPackageVersionsRequest$format": "

The format of the package versions to be copied.

", "DeletePackageRequest$format": "

The format of the requested package to delete.

", "DeletePackageVersionsRequest$format": "

The format of the package versions to delete.

", "DescribePackageRequest$format": "

A format that specifies the type of the requested package.

", "DescribePackageVersionRequest$format": "

A format that specifies the type of the requested package version.

", "DisposePackageVersionsRequest$format": "

A format that specifies the type of package versions you want to dispose.

", + "GetAssociatedPackageGroupRequest$format": "

The format of the package from which to get the associated package group.

", "GetPackageVersionAssetRequest$format": "

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

", "GetPackageVersionReadmeRequest$format": "

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

", "GetPackageVersionReadmeResult$format": "

The format of the package with the requested readme file.

", @@ -712,15 +869,154 @@ "UpdatePackageVersionsStatusRequest$format": "

A format that specifies the type of the package with the statuses to update.

" } }, + "PackageGroupAllowedRepository": { + "base": "

Details about an allowed repository for a package group, including its name and origin configuration.

", + "refs": { + "PackageGroupAllowedRepositoryList$member": null + } + }, + "PackageGroupAllowedRepositoryList": { + "base": null, + "refs": { + "UpdatePackageGroupOriginConfigurationRequest$addAllowedRepositories": "

The repository name and restrictions to add to the allowed repository list of the specified package group.

", + "UpdatePackageGroupOriginConfigurationRequest$removeAllowedRepositories": "

The repository name and restrictions to remove from the allowed repository list of the specified package group.

" + } + }, + "PackageGroupAllowedRepositoryUpdate": { + "base": null, + "refs": { + "PackageGroupAllowedRepositoryUpdates$value": null + } + }, + "PackageGroupAllowedRepositoryUpdateType": { + "base": null, + "refs": { + "PackageGroupAllowedRepositoryUpdate$key": null + } + }, + "PackageGroupAllowedRepositoryUpdates": { + "base": null, + "refs": { + "UpdatePackageGroupOriginConfigurationResult$allowedRepositoryUpdates": "

Information about the updated allowed repositories after processing the request.

" + } + }, + "PackageGroupAssociationType": { + "base": null, + "refs": { + "AssociatedPackage$associationType": "

Describes the strength of the association between the package and package group. A strong match can be thought of as an exact match, and a weak match can be thought of as a variation match, for example, the package name matches a variation of the package group pattern. For more information about package group pattern matching, including strong and weak matches, see Package group definition syntax and matching behavior in the CodeArtifact User Guide.

", + "GetAssociatedPackageGroupResult$associationType": "

Describes the strength of the association between the package and package group. A strong match is also known as an exact match, and a weak match is known as a relative match.

" + } + }, + "PackageGroupContactInfo": { + "base": null, + "refs": { + "CreatePackageGroupRequest$contactInfo": "

The contact information for the created package group.

", + "PackageGroupDescription$contactInfo": "

The contact information of the package group.

", + "PackageGroupSummary$contactInfo": "

The contact information of the package group.

", + "UpdatePackageGroupRequest$contactInfo": "

Contact information which you want to update the requested package group with.

" + } + }, + "PackageGroupDescription": { + "base": "

The description of the package group.

", + "refs": { + "CreatePackageGroupResult$packageGroup": "

Information about the created package group after processing the request.

", + "DeletePackageGroupResult$packageGroup": "

Information about the deleted package group after processing the request.

", + "DescribePackageGroupResult$packageGroup": "

A PackageGroupDescription object that contains information about the requested package group.

", + "GetAssociatedPackageGroupResult$packageGroup": "

The package group that is associated with the requested package.

", + "UpdatePackageGroupOriginConfigurationResult$packageGroup": "

The package group and information about it after processing the request.

", + "UpdatePackageGroupResult$packageGroup": "

The package group and information about it after the request has been processed.

" + } + }, + "PackageGroupOriginConfiguration": { + "base": "

The package group origin configuration that determines how package versions can enter repositories.

", + "refs": { + "PackageGroupDescription$originConfiguration": "

The package group origin configuration that determines how package versions can enter repositories.

", + "PackageGroupSummary$originConfiguration": "

Details about the package origin configuration of a package group.

" + } + }, + "PackageGroupOriginRestriction": { + "base": "

Contains information about the configured restrictions of the origin controls of a package group.

", + "refs": { + "PackageGroupOriginRestrictions$value": null + } + }, + "PackageGroupOriginRestrictionMode": { + "base": null, + "refs": { + "OriginRestrictions$value": null, + "PackageGroupOriginRestriction$mode": "

The package group origin restriction setting. If the value of mode is ALLOW, ALLOW_SPECIFIC_REPOSITORIES, or BLOCK, then the value of effectiveMode is the same. Otherwise, when the value is INHERIT, then the value of effectiveMode is the value of mode of the first parent group which does not have a value of INHERIT.

", + "PackageGroupOriginRestriction$effectiveMode": "

The effective package group origin restriction setting. If the value of mode is ALLOW, ALLOW_SPECIFIC_REPOSITORIES, or BLOCK, then the value of effectiveMode is the same. Otherwise, when the value of mode is INHERIT, then the value of effectiveMode is the value of mode of the first parent group which does not have a value of INHERIT.

" + } + }, + "PackageGroupOriginRestrictionType": { + "base": null, + "refs": { + "ListAllowedRepositoriesForGroupRequest$originRestrictionType": "

The origin configuration restriction type of which to list allowed repositories.

", + "OriginRestrictions$key": null, + "PackageGroupAllowedRepository$originRestrictionType": "

The origin configuration restriction type of the allowed repository.

", + "PackageGroupAllowedRepositoryUpdates$key": null, + "PackageGroupOriginRestrictions$key": null + } + }, + "PackageGroupOriginRestrictions": { + "base": null, + "refs": { + "PackageGroupOriginConfiguration$restrictions": "

The origin configuration settings that determine how package versions can enter repositories.

" + } + }, + "PackageGroupPattern": { + "base": null, + "refs": { + "CreatePackageGroupRequest$packageGroup": "

The pattern of the package group to create. The pattern is also the identifier of the package group.

", + "DescribePackageGroupRequest$packageGroup": "

The pattern of the requested package group.

", + "ListAllowedRepositoriesForGroupRequest$packageGroup": "

The pattern of the package group from which to list allowed repositories.

", + "ListAssociatedPackagesRequest$packageGroup": "

The pattern of the package group from which to list associated packages.

", + "ListSubPackageGroupsRequest$packageGroup": "

The pattern of the package group from which to list sub package groups.

", + "PackageGroupDescription$pattern": "

The pattern of the package group. The pattern determines which packages are associated with the package group.

", + "PackageGroupReference$pattern": "

The pattern of the package group. The pattern determines which packages are associated with the package group, and is also the identifier of the package group.

", + "PackageGroupSummary$pattern": "

The pattern of the package group. The pattern determines which packages are associated with the package group.

", + "UpdatePackageGroupOriginConfigurationRequest$packageGroup": "

The pattern of the package group for which to update the origin configuration.

", + "UpdatePackageGroupRequest$packageGroup": "

The pattern of the package group to be updated.

" + } + }, + "PackageGroupPatternPrefix": { + "base": null, + "refs": { + "ListPackageGroupsRequest$prefix": "

A prefix for which to search package groups. When included, ListPackageGroups will return only package groups with patterns that match the prefix.

" + } + }, + "PackageGroupReference": { + "base": "

Information about the identifiers of a package group.

", + "refs": { + "PackageGroupDescription$parent": "

The direct parent package group of the package group.

", + "PackageGroupOriginRestriction$inheritedFrom": "

The parent package group that the package group origin restrictions are inherited from.

", + "PackageGroupSummary$parent": "

The direct parent package group of the package group.

" + } + }, + "PackageGroupSummary": { + "base": "

Details about a package group.

", + "refs": { + "PackageGroupSummaryList$member": null + } + }, + "PackageGroupSummaryList": { + "base": null, + "refs": { + "ListPackageGroupsResult$packageGroups": "

The list of package groups in the requested domain.

", + "ListSubPackageGroupsResult$packageGroups": "

A list of sub package groups for the requested package group.

" + } + }, "PackageName": { "base": null, "refs": { + "AssociatedPackage$package": "

The name of the associated package.

", "CopyPackageVersionsRequest$package": "

The name of the package that contains the versions to be copied.

", "DeletePackageRequest$package": "

The name of the package to delete.

", "DeletePackageVersionsRequest$package": "

The name of the package with the versions to delete.

", "DescribePackageRequest$package": "

The name of the requested package.

", "DescribePackageVersionRequest$package": "

The name of the requested package version.

", "DisposePackageVersionsRequest$package": "

The name of the package with the versions you want to dispose.

", + "GetAssociatedPackageGroupRequest$package": "

The package from which to get the associated package group.

", "GetPackageVersionAssetRequest$package": "

The name of the package that contains the requested asset.

", "GetPackageVersionReadmeRequest$package": "

The name of the package version that contains the requested readme file.

", "GetPackageVersionReadmeResult$package": "

The name of the package that contains the returned readme file.

", @@ -744,30 +1040,32 @@ "PackageNamespace": { "base": null, "refs": { - "CopyPackageVersionsRequest$namespace": "

The namespace of the package versions to be copied. The package version component that specifies its namespace depends on its type. For example:

", - "DeletePackageRequest$namespace": "

The namespace of the package to delete. The package component that specifies its namespace depends on its type. For example:

", - "DeletePackageVersionsRequest$namespace": "

The namespace of the package versions to be deleted. The package version component that specifies its namespace depends on its type. For example:

", - "DescribePackageRequest$namespace": "

The namespace of the requested package. The package component that specifies its namespace depends on its type. For example:

", - "DescribePackageVersionRequest$namespace": "

The namespace of the requested package version. The package version component that specifies its namespace depends on its type. For example:

", - "DisposePackageVersionsRequest$namespace": "

The namespace of the package versions to be disposed. The package version component that specifies its namespace depends on its type. For example:

", - "GetPackageVersionAssetRequest$namespace": "

The namespace of the package version with the requested asset file. The package version component that specifies its namespace depends on its type. For example:

", - "GetPackageVersionReadmeRequest$namespace": "

The namespace of the package version with the requested readme file. The package version component that specifies its namespace depends on its type. For example:

", - "GetPackageVersionReadmeResult$namespace": "

The namespace of the package version with the requested readme file. The package version component that specifies its namespace depends on its type. For example:

", - "ListPackageVersionAssetsRequest$namespace": "

The namespace of the package version that contains the requested package version assets. The package version component that specifies its namespace depends on its type. For example:

", - "ListPackageVersionAssetsResult$namespace": "

The namespace of the package version that contains the requested package version assets. The package version component that specifies its namespace depends on its type. For example:

", - "ListPackageVersionDependenciesRequest$namespace": "

The namespace of the package version with the requested dependencies. The package version component that specifies its namespace depends on its type. For example:

", - "ListPackageVersionDependenciesResult$namespace": "

The namespace of the package version that contains the returned dependencies. The package version component that specifies its namespace depends on its type. For example:

", - "ListPackageVersionsRequest$namespace": "

The namespace of the package that contains the requested package versions. The package component that specifies its namespace depends on its type. For example:

", - "ListPackageVersionsResult$namespace": "

The namespace of the package that contains the requested package versions. The package component that specifies its namespace depends on its type. For example:

", - "ListPackagesRequest$namespace": "

The namespace prefix used to filter requested packages. Only packages with a namespace that starts with the provided string value are returned. Note that although this option is called --namespace and not --namespace-prefix, it has prefix-matching behavior.

Each package format uses namespace as follows:

", - "PackageDependency$namespace": "

The namespace of the package that this package depends on. The package component that specifies its namespace depends on its type. For example:

", - "PackageDescription$namespace": "

The namespace of the package. The package component that specifies its namespace depends on its type. For example:

", - "PackageSummary$namespace": "

The namespace of the package. The package component that specifies its namespace depends on its type. For example:

", - "PackageVersionDescription$namespace": "

The namespace of the package version. The package version component that specifies its namespace depends on its type. For example:

", + "AssociatedPackage$namespace": "

The namespace of the associated package. The package component that specifies its namespace depends on its type. For example:

", + "CopyPackageVersionsRequest$namespace": "

The namespace of the package versions to be copied. The package component that specifies its namespace depends on its type. For example:

The namespace is required when copying package versions of the following formats:

", + "DeletePackageRequest$namespace": "

The namespace of the package to delete. The package component that specifies its namespace depends on its type. For example:

The namespace is required when deleting packages of the following formats:

", + "DeletePackageVersionsRequest$namespace": "

The namespace of the package versions to be deleted. The package component that specifies its namespace depends on its type. For example:

The namespace is required when deleting package versions of the following formats:

", + "DescribePackageRequest$namespace": "

The namespace of the requested package. The package component that specifies its namespace depends on its type. For example:

The namespace is required when requesting packages of the following formats:

", + "DescribePackageVersionRequest$namespace": "

The namespace of the requested package version. The package component that specifies its namespace depends on its type. For example:

The namespace is required when requesting package versions of the following formats:

", + "DisposePackageVersionsRequest$namespace": "

The namespace of the package versions to be disposed. The package component that specifies its namespace depends on its type. For example:

The namespace is required when disposing package versions of the following formats:

", + "GetAssociatedPackageGroupRequest$namespace": "

The namespace of the package from which to get the associated package group. The package component that specifies its namespace depends on its type. For example:

The namespace is required when getting associated package groups from packages of the following formats:

", + "GetPackageVersionAssetRequest$namespace": "

The namespace of the package version with the requested asset file. The package component that specifies its namespace depends on its type. For example:

The namespace is required when requesting assets from package versions of the following formats:

", + "GetPackageVersionReadmeRequest$namespace": "

The namespace of the package version with the requested readme file. The package component that specifies its namespace depends on its type. For example:

The namespace is required when requesting the readme from package versions of the following formats:

", + "GetPackageVersionReadmeResult$namespace": "

The namespace of the package version with the requested readme file. The package component that specifies its namespace depends on its type. For example:

", + "ListPackageVersionAssetsRequest$namespace": "

The namespace of the package version that contains the requested package version assets. The package component that specifies its namespace depends on its type. For example:

The namespace is required requesting assets from package versions of the following formats:

", + "ListPackageVersionAssetsResult$namespace": "

The namespace of the package version that contains the requested package version assets. The package component that specifies its namespace depends on its type. For example:

", + "ListPackageVersionDependenciesRequest$namespace": "

The namespace of the package version with the requested dependencies. The package component that specifies its namespace depends on its type. For example:

The namespace is required when listing dependencies from package versions of the following formats:

", + "ListPackageVersionDependenciesResult$namespace": "

The namespace of the package version that contains the returned dependencies. The package component that specifies its namespace depends on its type. For example:

", + "ListPackageVersionsRequest$namespace": "

The namespace of the package that contains the requested package versions. The package component that specifies its namespace depends on its type. For example:

The namespace is required when deleting package versions of the following formats:

", + "ListPackageVersionsResult$namespace": "

The namespace of the package that contains the requested package versions. The package component that specifies its namespace depends on its type. For example:

", + "ListPackagesRequest$namespace": "

The namespace prefix used to filter requested packages. Only packages with a namespace that starts with the provided string value are returned. Note that although this option is called --namespace and not --namespace-prefix, it has prefix-matching behavior.

Each package format uses namespace as follows:

", + "PackageDependency$namespace": "

The namespace of the package that this package depends on. The package component that specifies its namespace depends on its type. For example:

", + "PackageDescription$namespace": "

The namespace of the package. The package component that specifies its namespace depends on its type. For example:

", + "PackageSummary$namespace": "

The namespace of the package. The package component that specifies its namespace depends on its type. For example:

", + "PackageVersionDescription$namespace": "

The namespace of the package version. The package component that specifies its namespace depends on its type. For example:

", "PublishPackageVersionRequest$namespace": "

The namespace of the package version to publish.

", "PublishPackageVersionResult$namespace": "

The namespace of the package version.

", - "PutPackageOriginConfigurationRequest$namespace": "

The namespace of the package to be updated. The package component that specifies its namespace depends on its type. For example:

", - "UpdatePackageVersionsStatusRequest$namespace": "

The namespace of the package version to be updated. The package version component that specifies its namespace depends on its type. For example:

" + "PutPackageOriginConfigurationRequest$namespace": "

The namespace of the package to be updated. The package component that specifies its namespace depends on its type. For example:

", + "UpdatePackageVersionsStatusRequest$namespace": "

The namespace of the package version to be updated. The package component that specifies its namespace depends on its type. For example:

" } }, "PackageOriginConfiguration": { @@ -928,8 +1226,14 @@ "PaginationToken": { "base": null, "refs": { + "ListAllowedRepositoriesForGroupRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", + "ListAllowedRepositoriesForGroupResult$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", + "ListAssociatedPackagesRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", + "ListAssociatedPackagesResult$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", "ListDomainsRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", "ListDomainsResult$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", + "ListPackageGroupsRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", + "ListPackageGroupsResult$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", "ListPackageVersionAssetsRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", "ListPackageVersionAssetsResult$nextToken": "

If there are additional results, this is the token for the next set of results.

", "ListPackageVersionDependenciesRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", @@ -941,7 +1245,9 @@ "ListRepositoriesInDomainRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", "ListRepositoriesInDomainResult$nextToken": "

If there are additional results, this is the token for the next set of results.

", "ListRepositoriesRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", - "ListRepositoriesResult$nextToken": "

If there are additional results, this is the token for the next set of results.

" + "ListRepositoriesResult$nextToken": "

If there are additional results, this is the token for the next set of results.

", + "ListSubPackageGroupsRequest$nextToken": "

The token for the next set of results. Use the value returned in the previous response in the next request to retrieve the next set of results.

", + "ListSubPackageGroupsResult$nextToken": "

If there are additional results, this is the token for the next set of results.

" } }, "PolicyDocument": { @@ -1031,7 +1337,7 @@ "AssociateExternalConnectionRequest$repository": "

The name of the repository to which the external connection is added.

", "CopyPackageVersionsRequest$sourceRepository": "

The name of the repository that contains the package versions to be copied.

", "CopyPackageVersionsRequest$destinationRepository": "

The name of the repository into which package versions are copied.

", - "CreateRepositoryRequest$repository": "

The name of the repository to create.

", + "CreateRepositoryRequest$repository": "

The name of the repository to create.

", "DeletePackageRequest$repository": "

The name of the repository that contains the package to delete.

", "DeletePackageVersionsRequest$repository": "

The name of the repository that contains the package versions to delete.

", "DeleteRepositoryPermissionsPolicyRequest$repository": "

The name of the repository that is associated with the resource policy to be deleted

", @@ -1052,10 +1358,12 @@ "ListPackagesRequest$repository": "

The name of the repository that contains the requested packages.

", "ListRepositoriesInDomainRequest$repositoryPrefix": "

A prefix used to filter returned repositories. Only repositories with names that start with repositoryPrefix are returned.

", "ListRepositoriesRequest$repositoryPrefix": "

A prefix used to filter returned repositories. Only repositories with names that start with repositoryPrefix are returned.

", + "PackageGroupAllowedRepository$repositoryName": "

The name of the allowed repository.

", "PublishPackageVersionRequest$repository": "

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

", "PutPackageOriginConfigurationRequest$repository": "

The name of the repository that contains the package.

", "PutRepositoryPermissionsPolicyRequest$repository": "

The name of the repository to set the resource policy on.

", "RepositoryDescription$name": "

The name of the repository.

", + "RepositoryNameList$member": null, "RepositorySummary$name": "

The name of the repository.

", "UpdatePackageVersionsStatusRequest$repository": "

The repository that contains the package versions with the status you want to update.

", "UpdateRepositoryRequest$repository": "

The name of the repository to update.

", @@ -1063,6 +1371,13 @@ "UpstreamRepositoryInfo$repositoryName": "

The name of an upstream repository.

" } }, + "RepositoryNameList": { + "base": null, + "refs": { + "ListAllowedRepositoriesForGroupResult$allowedRepositories": "

The list of allowed repositories for the package group and origin configuration restriction type.

", + "PackageGroupAllowedRepositoryUpdate$value": null + } + }, "RepositorySummary": { "base": "

Details about a repository, including its Amazon Resource Name (ARN), description, and domain information. The ListRepositories operation returns a list of RepositorySummary objects.

", "refs": { @@ -1123,6 +1438,7 @@ "AccessDeniedException$message": null, "ConflictException$message": null, "ConflictException$resourceId": "

The ID of the resource.

", + "DeletePackageGroupRequest$packageGroup": "

The pattern of the package group to be deleted.

", "GetAuthorizationTokenResult$authorizationToken": "

The returned authentication token.

", "GetPackageVersionReadmeResult$readme": "

The text of the returned readme file.

", "GetRepositoryEndpointResult$repositoryEndpoint": "

A string that specifies the URL of the returned endpoint.

", @@ -1187,6 +1503,7 @@ "base": null, "refs": { "CreateDomainRequest$tags": "

One or more tag key-value pairs for the domain.

", + "CreatePackageGroupRequest$tags": "

One or more tag key-value pairs for the package group.

", "CreateRepositoryRequest$tags": "

One or more tag key-value pairs for the repository.

", "ListTagsForResourceResult$tags": "

A list of tag key and value pairs associated with the specified resource.

", "TagResourceRequest$tags": "

The tags you want to modify or add to the resource.

" @@ -1219,6 +1536,8 @@ "DomainDescription$createdTime": "

A timestamp that represents the date and time the domain was created.

", "DomainSummary$createdTime": "

A timestamp that contains the date and time the domain was created.

", "GetAuthorizationTokenResult$expiration": "

A timestamp that specifies the date and time the authorization token expires.

", + "PackageGroupDescription$createdTime": "

A timestamp that represents the date and time the package group was created.

", + "PackageGroupSummary$createdTime": "

A timestamp that represents the date and time the repository was created.

", "PackageVersionDescription$publishedTime": "

A timestamp that contains the date and time the package version was published.

", "RepositoryDescription$createdTime": "

A timestamp that represents the date and time the repository was created.

", "RepositorySummary$createdTime": "

A timestamp that represents the date and time the repository was created.

" @@ -1234,6 +1553,26 @@ "refs": { } }, + "UpdatePackageGroupOriginConfigurationRequest": { + "base": null, + "refs": { + } + }, + "UpdatePackageGroupOriginConfigurationResult": { + "base": null, + "refs": { + } + }, + "UpdatePackageGroupRequest": { + "base": null, + "refs": { + } + }, + "UpdatePackageGroupResult": { + "base": null, + "refs": { + } + }, "UpdatePackageVersionsStatusRequest": { "base": null, "refs": { diff --git a/models/apis/codeartifact/2018-09-22/endpoint-rule-set-1.json b/models/apis/codeartifact/2018-09-22/endpoint-rule-set-1.json index a2bfb01a9e1..1ebd9d6fb73 100644 --- a/models/apis/codeartifact/2018-09-22/endpoint-rule-set-1.json +++ b/models/apis/codeartifact/2018-09-22/endpoint-rule-set-1.json @@ -40,7 +40,6 @@ ] } ], - "type": "tree", "rules": [ { "conditions": [ @@ -83,7 +82,8 @@ }, "type": "endpoint" } - ] + ], + "type": "tree" }, { "conditions": [ @@ -96,7 +96,6 @@ ] } ], - "type": "tree", "rules": [ { "conditions": [ @@ -110,7 +109,6 @@ "assign": "PartitionResult" } ], - "type": "tree", "rules": [ { "conditions": [ @@ -133,7 +131,6 @@ ] } ], - "type": "tree", "rules": [ { "conditions": [ @@ -168,7 +165,6 @@ ] } ], - "type": "tree", "rules": [ { "conditions": [], @@ -179,14 +175,16 @@ }, "type": "endpoint" } - ] + ], + "type": "tree" }, { "conditions": [], "error": "FIPS and DualStack are enabled, but this partition does not support one or both", "type": "error" } - ] + ], + "type": "tree" }, { "conditions": [ @@ -200,14 +198,12 @@ ] } ], - "type": "tree", "rules": [ { "conditions": [ { "fn": "booleanEquals", "argv": [ - true, { "fn": "getAttr", "argv": [ @@ -216,11 +212,11 @@ }, "supportsFIPS" ] - } + }, + true ] } ], - "type": "tree", "rules": [ { "conditions": [], @@ -231,14 +227,16 @@ }, "type": "endpoint" } - ] + ], + "type": "tree" }, { "conditions": [], "error": "FIPS is enabled but this partition does not support FIPS", "type": "error" } - ] + ], + "type": "tree" }, { "conditions": [ @@ -252,7 +250,6 @@ ] } ], - "type": "tree", "rules": [ { "conditions": [ @@ -272,7 +269,6 @@ ] } ], - "type": "tree", "rules": [ { "conditions": [], @@ -283,14 +279,16 @@ }, "type": "endpoint" } - ] + ], + "type": "tree" }, { "conditions": [], "error": "DualStack is enabled but this partition does not support DualStack", "type": "error" } - ] + ], + "type": "tree" }, { "conditions": [], @@ -301,9 +299,11 @@ }, "type": "endpoint" } - ] + ], + "type": "tree" } - ] + ], + "type": "tree" }, { "conditions": [], diff --git a/models/apis/codeartifact/2018-09-22/paginators-1.json b/models/apis/codeartifact/2018-09-22/paginators-1.json index ef8602842eb..b2d125a5dff 100644 --- a/models/apis/codeartifact/2018-09-22/paginators-1.json +++ b/models/apis/codeartifact/2018-09-22/paginators-1.json @@ -1,11 +1,29 @@ { "pagination": { + "ListAllowedRepositoriesForGroup": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxResults", + "result_key": "allowedRepositories" + }, + "ListAssociatedPackages": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxResults", + "result_key": "packages" + }, "ListDomains": { "input_token": "nextToken", "output_token": "nextToken", "limit_key": "maxResults", "result_key": "domains" }, + "ListPackageGroups": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxResults", + "result_key": "packageGroups" + }, "ListPackageVersionAssets": { "input_token": "nextToken", "output_token": "nextToken", @@ -35,6 +53,12 @@ "output_token": "nextToken", "limit_key": "maxResults", "result_key": "repositories" + }, + "ListSubPackageGroups": { + "input_token": "nextToken", + "output_token": "nextToken", + "limit_key": "maxResults", + "result_key": "packageGroups" } } } diff --git a/service/codeartifact/api.go b/service/codeartifact/api.go index f14acb81855..c20977dbb96 100644 --- a/service/codeartifact/api.go +++ b/service/codeartifact/api.go @@ -328,6 +328,108 @@ func (c *CodeArtifact) CreateDomainWithContext(ctx aws.Context, input *CreateDom return out, req.Send() } +const opCreatePackageGroup = "CreatePackageGroup" + +// CreatePackageGroupRequest generates a "aws/request.Request" representing the +// client's request for the CreatePackageGroup operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See CreatePackageGroup for more information on using the CreatePackageGroup +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the CreatePackageGroupRequest method. +// req, resp := client.CreatePackageGroupRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/CreatePackageGroup +func (c *CodeArtifact) CreatePackageGroupRequest(input *CreatePackageGroupInput) (req *request.Request, output *CreatePackageGroupOutput) { + op := &request.Operation{ + Name: opCreatePackageGroup, + HTTPMethod: "POST", + HTTPPath: "/v1/package-group", + } + + if input == nil { + input = &CreatePackageGroupInput{} + } + + output = &CreatePackageGroupOutput{} + req = c.newRequest(op, input, output) + return +} + +// CreatePackageGroup API operation for CodeArtifact. +// +// Creates a package group. For more information about creating package groups, +// including example CLI commands, see Create a package group (https://docs.aws.amazon.com/codeartifact/latest/ug/create-package-group.html) +// in the CodeArtifact User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation CreatePackageGroup for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - ConflictException +// The operation did not succeed because prerequisites are not met. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// +// - ServiceQuotaExceededException +// The operation did not succeed because it would have exceeded a service limit +// for your account. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/CreatePackageGroup +func (c *CodeArtifact) CreatePackageGroup(input *CreatePackageGroupInput) (*CreatePackageGroupOutput, error) { + req, out := c.CreatePackageGroupRequest(input) + return out, req.Send() +} + +// CreatePackageGroupWithContext is the same as CreatePackageGroup with the addition of +// the ability to pass a context and additional request options. +// +// See CreatePackageGroup for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) CreatePackageGroupWithContext(ctx aws.Context, input *CreatePackageGroupInput, opts ...request.Option) (*CreatePackageGroupOutput, error) { + req, out := c.CreatePackageGroupRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opCreateRepository = "CreateRepository" // CreateRepositoryRequest generates a "aws/request.Request" representing the @@ -716,6 +818,110 @@ func (c *CodeArtifact) DeletePackageWithContext(ctx aws.Context, input *DeletePa return out, req.Send() } +const opDeletePackageGroup = "DeletePackageGroup" + +// DeletePackageGroupRequest generates a "aws/request.Request" representing the +// client's request for the DeletePackageGroup operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DeletePackageGroup for more information on using the DeletePackageGroup +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the DeletePackageGroupRequest method. +// req, resp := client.DeletePackageGroupRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/DeletePackageGroup +func (c *CodeArtifact) DeletePackageGroupRequest(input *DeletePackageGroupInput) (req *request.Request, output *DeletePackageGroupOutput) { + op := &request.Operation{ + Name: opDeletePackageGroup, + HTTPMethod: "DELETE", + HTTPPath: "/v1/package-group", + } + + if input == nil { + input = &DeletePackageGroupInput{} + } + + output = &DeletePackageGroupOutput{} + req = c.newRequest(op, input, output) + return +} + +// DeletePackageGroup API operation for CodeArtifact. +// +// Deletes a package group. Deleting a package group does not delete packages +// or package versions associated with the package group. When a package group +// is deleted, the direct child package groups will become children of the package +// group's direct parent package group. Therefore, if any of the child groups +// are inheriting any settings from the parent, those settings could change. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation DeletePackageGroup for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - ConflictException +// The operation did not succeed because prerequisites are not met. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// +// - ServiceQuotaExceededException +// The operation did not succeed because it would have exceeded a service limit +// for your account. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/DeletePackageGroup +func (c *CodeArtifact) DeletePackageGroup(input *DeletePackageGroupInput) (*DeletePackageGroupOutput, error) { + req, out := c.DeletePackageGroupRequest(input) + return out, req.Send() +} + +// DeletePackageGroupWithContext is the same as DeletePackageGroup with the addition of +// the ability to pass a context and additional request options. +// +// See DeletePackageGroup for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) DeletePackageGroupWithContext(ctx aws.Context, input *DeletePackageGroupInput, opts ...request.Option) (*DeletePackageGroupOutput, error) { + req, out := c.DeletePackageGroupRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDeletePackageVersions = "DeletePackageVersions" // DeletePackageVersionsRequest generates a "aws/request.Request" representing the @@ -1203,6 +1409,100 @@ func (c *CodeArtifact) DescribePackageWithContext(ctx aws.Context, input *Descri return out, req.Send() } +const opDescribePackageGroup = "DescribePackageGroup" + +// DescribePackageGroupRequest generates a "aws/request.Request" representing the +// client's request for the DescribePackageGroup operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See DescribePackageGroup for more information on using the DescribePackageGroup +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the DescribePackageGroupRequest method. +// req, resp := client.DescribePackageGroupRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/DescribePackageGroup +func (c *CodeArtifact) DescribePackageGroupRequest(input *DescribePackageGroupInput) (req *request.Request, output *DescribePackageGroupOutput) { + op := &request.Operation{ + Name: opDescribePackageGroup, + HTTPMethod: "GET", + HTTPPath: "/v1/package-group", + } + + if input == nil { + input = &DescribePackageGroupInput{} + } + + output = &DescribePackageGroupOutput{} + req = c.newRequest(op, input, output) + return +} + +// DescribePackageGroup API operation for CodeArtifact. +// +// Returns a PackageGroupDescription (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageGroupDescription.html) +// object that contains information about the requested package group. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation DescribePackageGroup for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/DescribePackageGroup +func (c *CodeArtifact) DescribePackageGroup(input *DescribePackageGroupInput) (*DescribePackageGroupOutput, error) { + req, out := c.DescribePackageGroupRequest(input) + return out, req.Send() +} + +// DescribePackageGroupWithContext is the same as DescribePackageGroup with the addition of +// the ability to pass a context and additional request options. +// +// See DescribePackageGroup for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) DescribePackageGroupWithContext(ctx aws.Context, input *DescribePackageGroupInput, opts ...request.Option) (*DescribePackageGroupOutput, error) { + req, out := c.DescribePackageGroupRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + const opDescribePackageVersion = "DescribePackageVersion" // DescribePackageVersionRequest generates a "aws/request.Request" representing the @@ -1600,63 +1900,162 @@ func (c *CodeArtifact) DisposePackageVersionsWithContext(ctx aws.Context, input return out, req.Send() } -const opGetAuthorizationToken = "GetAuthorizationToken" +const opGetAssociatedPackageGroup = "GetAssociatedPackageGroup" -// GetAuthorizationTokenRequest generates a "aws/request.Request" representing the -// client's request for the GetAuthorizationToken operation. The "output" return +// GetAssociatedPackageGroupRequest generates a "aws/request.Request" representing the +// client's request for the GetAssociatedPackageGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See GetAuthorizationToken for more information on using the GetAuthorizationToken +// See GetAssociatedPackageGroup for more information on using the GetAssociatedPackageGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the GetAuthorizationTokenRequest method. -// req, resp := client.GetAuthorizationTokenRequest(params) +// // Example sending a request using the GetAssociatedPackageGroupRequest method. +// req, resp := client.GetAssociatedPackageGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/GetAuthorizationToken -func (c *CodeArtifact) GetAuthorizationTokenRequest(input *GetAuthorizationTokenInput) (req *request.Request, output *GetAuthorizationTokenOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/GetAssociatedPackageGroup +func (c *CodeArtifact) GetAssociatedPackageGroupRequest(input *GetAssociatedPackageGroupInput) (req *request.Request, output *GetAssociatedPackageGroupOutput) { op := &request.Operation{ - Name: opGetAuthorizationToken, - HTTPMethod: "POST", - HTTPPath: "/v1/authorization-token", + Name: opGetAssociatedPackageGroup, + HTTPMethod: "GET", + HTTPPath: "/v1/get-associated-package-group", } if input == nil { - input = &GetAuthorizationTokenInput{} + input = &GetAssociatedPackageGroupInput{} } - output = &GetAuthorizationTokenOutput{} + output = &GetAssociatedPackageGroupOutput{} req = c.newRequest(op, input, output) return } -// GetAuthorizationToken API operation for CodeArtifact. +// GetAssociatedPackageGroup API operation for CodeArtifact. // -// Generates a temporary authorization token for accessing repositories in the -// domain. This API requires the codeartifact:GetAuthorizationToken and sts:GetServiceBearerToken -// permissions. For more information about authorization tokens, see CodeArtifact -// authentication and tokens (https://docs.aws.amazon.com/codeartifact/latest/ug/tokens-authentication.html). +// Returns the most closely associated package group to the specified package. +// This API does not require that the package exist in any repository in the +// domain. As such, GetAssociatedPackageGroup can be used to see which package +// group's origin configuration applies to a package before that package is +// in a repository. This can be helpful to check if public packages are blocked +// without ingesting them. // -// CodeArtifact authorization tokens are valid for a period of 12 hours when -// created with the login command. You can call login periodically to refresh -// the token. When you create an authorization token with the GetAuthorizationToken -// API, you can set a custom authorization period, up to a maximum of 12 hours, -// with the durationSeconds parameter. +// For information package group association and matching, see Package group +// definition syntax and matching behavior (https://docs.aws.amazon.com/codeartifact/latest/ug/package-group-definition-syntax-matching-behavior.html) +// in the CodeArtifact User Guide. // -// The authorization period begins after login or GetAuthorizationToken is called. -// If login or GetAuthorizationToken is called while assuming a role, the token -// lifetime is independent of the maximum session duration of the role. For +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation GetAssociatedPackageGroup for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/GetAssociatedPackageGroup +func (c *CodeArtifact) GetAssociatedPackageGroup(input *GetAssociatedPackageGroupInput) (*GetAssociatedPackageGroupOutput, error) { + req, out := c.GetAssociatedPackageGroupRequest(input) + return out, req.Send() +} + +// GetAssociatedPackageGroupWithContext is the same as GetAssociatedPackageGroup with the addition of +// the ability to pass a context and additional request options. +// +// See GetAssociatedPackageGroup for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) GetAssociatedPackageGroupWithContext(ctx aws.Context, input *GetAssociatedPackageGroupInput, opts ...request.Option) (*GetAssociatedPackageGroupOutput, error) { + req, out := c.GetAssociatedPackageGroupRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opGetAuthorizationToken = "GetAuthorizationToken" + +// GetAuthorizationTokenRequest generates a "aws/request.Request" representing the +// client's request for the GetAuthorizationToken operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See GetAuthorizationToken for more information on using the GetAuthorizationToken +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the GetAuthorizationTokenRequest method. +// req, resp := client.GetAuthorizationTokenRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/GetAuthorizationToken +func (c *CodeArtifact) GetAuthorizationTokenRequest(input *GetAuthorizationTokenInput) (req *request.Request, output *GetAuthorizationTokenOutput) { + op := &request.Operation{ + Name: opGetAuthorizationToken, + HTTPMethod: "POST", + HTTPPath: "/v1/authorization-token", + } + + if input == nil { + input = &GetAuthorizationTokenInput{} + } + + output = &GetAuthorizationTokenOutput{} + req = c.newRequest(op, input, output) + return +} + +// GetAuthorizationToken API operation for CodeArtifact. +// +// Generates a temporary authorization token for accessing repositories in the +// domain. This API requires the codeartifact:GetAuthorizationToken and sts:GetServiceBearerToken +// permissions. For more information about authorization tokens, see CodeArtifact +// authentication and tokens (https://docs.aws.amazon.com/codeartifact/latest/ug/tokens-authentication.html). +// +// CodeArtifact authorization tokens are valid for a period of 12 hours when +// created with the login command. You can call login periodically to refresh +// the token. When you create an authorization token with the GetAuthorizationToken +// API, you can set a custom authorization period, up to a maximum of 12 hours, +// with the durationSeconds parameter. +// +// The authorization period begins after login or GetAuthorizationToken is called. +// If login or GetAuthorizationToken is called while assuming a role, the token +// lifetime is independent of the maximum session duration of the role. For // example, if you call sts assume-role and specify a session duration of 15 // minutes, then generate a CodeArtifact authorization token, the token will // be valid for the full authorization period even though this is longer than @@ -2051,6 +2450,8 @@ func (c *CodeArtifact) GetRepositoryEndpointRequest(input *GetRepositoryEndpoint // Returns the endpoint of a repository for a specific package format. A repository // has one endpoint for each package format: // +// - generic +// // - maven // // - npm @@ -2059,6 +2460,8 @@ func (c *CodeArtifact) GetRepositoryEndpointRequest(input *GetRepositoryEndpoint // // - pypi // +// - swift +// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. @@ -2200,36 +2603,36 @@ func (c *CodeArtifact) GetRepositoryPermissionsPolicyWithContext(ctx aws.Context return out, req.Send() } -const opListDomains = "ListDomains" +const opListAllowedRepositoriesForGroup = "ListAllowedRepositoriesForGroup" -// ListDomainsRequest generates a "aws/request.Request" representing the -// client's request for the ListDomains operation. The "output" return +// ListAllowedRepositoriesForGroupRequest generates a "aws/request.Request" representing the +// client's request for the ListAllowedRepositoriesForGroup operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListDomains for more information on using the ListDomains +// See ListAllowedRepositoriesForGroup for more information on using the ListAllowedRepositoriesForGroup // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListDomainsRequest method. -// req, resp := client.ListDomainsRequest(params) +// // Example sending a request using the ListAllowedRepositoriesForGroupRequest method. +// req, resp := client.ListAllowedRepositoriesForGroupRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListDomains -func (c *CodeArtifact) ListDomainsRequest(input *ListDomainsInput) (req *request.Request, output *ListDomainsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListAllowedRepositoriesForGroup +func (c *CodeArtifact) ListAllowedRepositoriesForGroupRequest(input *ListAllowedRepositoriesForGroupInput) (req *request.Request, output *ListAllowedRepositoriesForGroupOutput) { op := &request.Operation{ - Name: opListDomains, - HTTPMethod: "POST", - HTTPPath: "/v1/domains", + Name: opListAllowedRepositoriesForGroup, + HTTPMethod: "GET", + HTTPPath: "/v1/package-group-allowed-repositories", Paginator: &request.Paginator{ InputTokens: []string{"nextToken"}, OutputTokens: []string{"nextToken"}, @@ -2239,27 +2642,27 @@ func (c *CodeArtifact) ListDomainsRequest(input *ListDomainsInput) (req *request } if input == nil { - input = &ListDomainsInput{} + input = &ListAllowedRepositoriesForGroupInput{} } - output = &ListDomainsOutput{} + output = &ListAllowedRepositoriesForGroupOutput{} req = c.newRequest(op, input, output) return } -// ListDomains API operation for CodeArtifact. +// ListAllowedRepositoriesForGroup API operation for CodeArtifact. // -// Returns a list of DomainSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionDescription.html) -// objects for all domains owned by the Amazon Web Services account that makes -// this call. Each returned DomainSummary object contains information about -// a domain. +// Lists the repositories in the added repositories list of the specified restriction +// type for a package group. For more information about restriction types and +// added repository lists, see Package group origin controls (https://docs.aws.amazon.com/codeartifact/latest/ug/package-group-origin-controls.html) +// in the CodeArtifact User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation ListDomains for usage and error information. +// API operation ListAllowedRepositoriesForGroup for usage and error information. // // Returned Error Types: // @@ -2269,6 +2672,10 @@ func (c *CodeArtifact) ListDomainsRequest(input *ListDomainsInput) (req *request // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // +// - ServiceQuotaExceededException +// The operation did not succeed because it would have exceeded a service limit +// for your account. +// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -2276,64 +2683,68 @@ func (c *CodeArtifact) ListDomainsRequest(input *ListDomainsInput) (req *request // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListDomains -func (c *CodeArtifact) ListDomains(input *ListDomainsInput) (*ListDomainsOutput, error) { - req, out := c.ListDomainsRequest(input) +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListAllowedRepositoriesForGroup +func (c *CodeArtifact) ListAllowedRepositoriesForGroup(input *ListAllowedRepositoriesForGroupInput) (*ListAllowedRepositoriesForGroupOutput, error) { + req, out := c.ListAllowedRepositoriesForGroupRequest(input) return out, req.Send() } -// ListDomainsWithContext is the same as ListDomains with the addition of +// ListAllowedRepositoriesForGroupWithContext is the same as ListAllowedRepositoriesForGroup with the addition of // the ability to pass a context and additional request options. // -// See ListDomains for details on how to use this API operation. +// See ListAllowedRepositoriesForGroup for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListDomainsWithContext(ctx aws.Context, input *ListDomainsInput, opts ...request.Option) (*ListDomainsOutput, error) { - req, out := c.ListDomainsRequest(input) +func (c *CodeArtifact) ListAllowedRepositoriesForGroupWithContext(ctx aws.Context, input *ListAllowedRepositoriesForGroupInput, opts ...request.Option) (*ListAllowedRepositoriesForGroupOutput, error) { + req, out := c.ListAllowedRepositoriesForGroupRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListDomainsPages iterates over the pages of a ListDomains operation, +// ListAllowedRepositoriesForGroupPages iterates over the pages of a ListAllowedRepositoriesForGroup operation, // calling the "fn" function with the response data for each page. To stop // iterating, return false from the fn function. // -// See ListDomains method for more information on how to use this operation. +// See ListAllowedRepositoriesForGroup method for more information on how to use this operation. // // Note: This operation can generate multiple requests to a service. // -// // Example iterating over at most 3 pages of a ListDomains operation. +// // Example iterating over at most 3 pages of a ListAllowedRepositoriesForGroup operation. // pageNum := 0 -// err := client.ListDomainsPages(params, -// func(page *codeartifact.ListDomainsOutput, lastPage bool) bool { +// err := client.ListAllowedRepositoriesForGroupPages(params, +// func(page *codeartifact.ListAllowedRepositoriesForGroupOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 // }) -func (c *CodeArtifact) ListDomainsPages(input *ListDomainsInput, fn func(*ListDomainsOutput, bool) bool) error { - return c.ListDomainsPagesWithContext(aws.BackgroundContext(), input, fn) +func (c *CodeArtifact) ListAllowedRepositoriesForGroupPages(input *ListAllowedRepositoriesForGroupInput, fn func(*ListAllowedRepositoriesForGroupOutput, bool) bool) error { + return c.ListAllowedRepositoriesForGroupPagesWithContext(aws.BackgroundContext(), input, fn) } -// ListDomainsPagesWithContext same as ListDomainsPages except +// ListAllowedRepositoriesForGroupPagesWithContext same as ListAllowedRepositoriesForGroupPages except // it takes a Context and allows setting request options on the pages. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListDomainsPagesWithContext(ctx aws.Context, input *ListDomainsInput, fn func(*ListDomainsOutput, bool) bool, opts ...request.Option) error { +func (c *CodeArtifact) ListAllowedRepositoriesForGroupPagesWithContext(ctx aws.Context, input *ListAllowedRepositoriesForGroupInput, fn func(*ListAllowedRepositoriesForGroupOutput, bool) bool, opts ...request.Option) error { p := request.Pagination{ NewRequest: func() (*request.Request, error) { - var inCpy *ListDomainsInput + var inCpy *ListAllowedRepositoriesForGroupInput if input != nil { tmp := *input inCpy = &tmp } - req, _ := c.ListDomainsRequest(inCpy) + req, _ := c.ListAllowedRepositoriesForGroupRequest(inCpy) req.SetContext(ctx) req.ApplyOptions(opts...) return req, nil @@ -2341,7 +2752,7 @@ func (c *CodeArtifact) ListDomainsPagesWithContext(ctx aws.Context, input *ListD } for p.Next() { - if !fn(p.Page().(*ListDomainsOutput), !p.HasNextPage()) { + if !fn(p.Page().(*ListAllowedRepositoriesForGroupOutput), !p.HasNextPage()) { break } } @@ -2349,36 +2760,36 @@ func (c *CodeArtifact) ListDomainsPagesWithContext(ctx aws.Context, input *ListD return p.Err() } -const opListPackageVersionAssets = "ListPackageVersionAssets" +const opListAssociatedPackages = "ListAssociatedPackages" -// ListPackageVersionAssetsRequest generates a "aws/request.Request" representing the -// client's request for the ListPackageVersionAssets operation. The "output" return +// ListAssociatedPackagesRequest generates a "aws/request.Request" representing the +// client's request for the ListAssociatedPackages operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListPackageVersionAssets for more information on using the ListPackageVersionAssets +// See ListAssociatedPackages for more information on using the ListAssociatedPackages // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListPackageVersionAssetsRequest method. -// req, resp := client.ListPackageVersionAssetsRequest(params) +// // Example sending a request using the ListAssociatedPackagesRequest method. +// req, resp := client.ListAssociatedPackagesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersionAssets -func (c *CodeArtifact) ListPackageVersionAssetsRequest(input *ListPackageVersionAssetsInput) (req *request.Request, output *ListPackageVersionAssetsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListAssociatedPackages +func (c *CodeArtifact) ListAssociatedPackagesRequest(input *ListAssociatedPackagesInput) (req *request.Request, output *ListAssociatedPackagesOutput) { op := &request.Operation{ - Name: opListPackageVersionAssets, - HTTPMethod: "POST", - HTTPPath: "/v1/package/version/assets", + Name: opListAssociatedPackages, + HTTPMethod: "GET", + HTTPPath: "/v1/list-associated-packages", Paginator: &request.Paginator{ InputTokens: []string{"nextToken"}, OutputTokens: []string{"nextToken"}, @@ -2388,25 +2799,27 @@ func (c *CodeArtifact) ListPackageVersionAssetsRequest(input *ListPackageVersion } if input == nil { - input = &ListPackageVersionAssetsInput{} + input = &ListAssociatedPackagesInput{} } - output = &ListPackageVersionAssetsOutput{} + output = &ListAssociatedPackagesOutput{} req = c.newRequest(op, input, output) return } -// ListPackageVersionAssets API operation for CodeArtifact. +// ListAssociatedPackages API operation for CodeArtifact. // -// Returns a list of AssetSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_AssetSummary.html) -// objects for assets in a package version. +// Returns a list of packages associated with the requested package group. For +// information package group association and matching, see Package group definition +// syntax and matching behavior (https://docs.aws.amazon.com/codeartifact/latest/ug/package-group-definition-syntax-matching-behavior.html) +// in the CodeArtifact User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation ListPackageVersionAssets for usage and error information. +// API operation ListAssociatedPackages for usage and error information. // // Returned Error Types: // @@ -2416,75 +2829,72 @@ func (c *CodeArtifact) ListPackageVersionAssetsRequest(input *ListPackageVersion // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // -// - ResourceNotFoundException -// The operation did not succeed because the resource requested is not found -// in the service. -// -// - ThrottlingException -// The operation did not succeed because too many requests are sent to the service. -// // - ValidationException // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersionAssets -func (c *CodeArtifact) ListPackageVersionAssets(input *ListPackageVersionAssetsInput) (*ListPackageVersionAssetsOutput, error) { - req, out := c.ListPackageVersionAssetsRequest(input) +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListAssociatedPackages +func (c *CodeArtifact) ListAssociatedPackages(input *ListAssociatedPackagesInput) (*ListAssociatedPackagesOutput, error) { + req, out := c.ListAssociatedPackagesRequest(input) return out, req.Send() } -// ListPackageVersionAssetsWithContext is the same as ListPackageVersionAssets with the addition of +// ListAssociatedPackagesWithContext is the same as ListAssociatedPackages with the addition of // the ability to pass a context and additional request options. // -// See ListPackageVersionAssets for details on how to use this API operation. +// See ListAssociatedPackages for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListPackageVersionAssetsWithContext(ctx aws.Context, input *ListPackageVersionAssetsInput, opts ...request.Option) (*ListPackageVersionAssetsOutput, error) { - req, out := c.ListPackageVersionAssetsRequest(input) +func (c *CodeArtifact) ListAssociatedPackagesWithContext(ctx aws.Context, input *ListAssociatedPackagesInput, opts ...request.Option) (*ListAssociatedPackagesOutput, error) { + req, out := c.ListAssociatedPackagesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListPackageVersionAssetsPages iterates over the pages of a ListPackageVersionAssets operation, +// ListAssociatedPackagesPages iterates over the pages of a ListAssociatedPackages operation, // calling the "fn" function with the response data for each page. To stop // iterating, return false from the fn function. // -// See ListPackageVersionAssets method for more information on how to use this operation. +// See ListAssociatedPackages method for more information on how to use this operation. // // Note: This operation can generate multiple requests to a service. // -// // Example iterating over at most 3 pages of a ListPackageVersionAssets operation. +// // Example iterating over at most 3 pages of a ListAssociatedPackages operation. // pageNum := 0 -// err := client.ListPackageVersionAssetsPages(params, -// func(page *codeartifact.ListPackageVersionAssetsOutput, lastPage bool) bool { +// err := client.ListAssociatedPackagesPages(params, +// func(page *codeartifact.ListAssociatedPackagesOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 // }) -func (c *CodeArtifact) ListPackageVersionAssetsPages(input *ListPackageVersionAssetsInput, fn func(*ListPackageVersionAssetsOutput, bool) bool) error { - return c.ListPackageVersionAssetsPagesWithContext(aws.BackgroundContext(), input, fn) +func (c *CodeArtifact) ListAssociatedPackagesPages(input *ListAssociatedPackagesInput, fn func(*ListAssociatedPackagesOutput, bool) bool) error { + return c.ListAssociatedPackagesPagesWithContext(aws.BackgroundContext(), input, fn) } -// ListPackageVersionAssetsPagesWithContext same as ListPackageVersionAssetsPages except +// ListAssociatedPackagesPagesWithContext same as ListAssociatedPackagesPages except // it takes a Context and allows setting request options on the pages. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListPackageVersionAssetsPagesWithContext(ctx aws.Context, input *ListPackageVersionAssetsInput, fn func(*ListPackageVersionAssetsOutput, bool) bool, opts ...request.Option) error { +func (c *CodeArtifact) ListAssociatedPackagesPagesWithContext(ctx aws.Context, input *ListAssociatedPackagesInput, fn func(*ListAssociatedPackagesOutput, bool) bool, opts ...request.Option) error { p := request.Pagination{ NewRequest: func() (*request.Request, error) { - var inCpy *ListPackageVersionAssetsInput + var inCpy *ListAssociatedPackagesInput if input != nil { tmp := *input inCpy = &tmp } - req, _ := c.ListPackageVersionAssetsRequest(inCpy) + req, _ := c.ListAssociatedPackagesRequest(inCpy) req.SetContext(ctx) req.ApplyOptions(opts...) return req, nil @@ -2492,7 +2902,7 @@ func (c *CodeArtifact) ListPackageVersionAssetsPagesWithContext(ctx aws.Context, } for p.Next() { - if !fn(p.Page().(*ListPackageVersionAssetsOutput), !p.HasNextPage()) { + if !fn(p.Page().(*ListAssociatedPackagesOutput), !p.HasNextPage()) { break } } @@ -2500,62 +2910,66 @@ func (c *CodeArtifact) ListPackageVersionAssetsPagesWithContext(ctx aws.Context, return p.Err() } -const opListPackageVersionDependencies = "ListPackageVersionDependencies" +const opListDomains = "ListDomains" -// ListPackageVersionDependenciesRequest generates a "aws/request.Request" representing the -// client's request for the ListPackageVersionDependencies operation. The "output" return +// ListDomainsRequest generates a "aws/request.Request" representing the +// client's request for the ListDomains operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListPackageVersionDependencies for more information on using the ListPackageVersionDependencies +// See ListDomains for more information on using the ListDomains // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListPackageVersionDependenciesRequest method. -// req, resp := client.ListPackageVersionDependenciesRequest(params) +// // Example sending a request using the ListDomainsRequest method. +// req, resp := client.ListDomainsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersionDependencies -func (c *CodeArtifact) ListPackageVersionDependenciesRequest(input *ListPackageVersionDependenciesInput) (req *request.Request, output *ListPackageVersionDependenciesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListDomains +func (c *CodeArtifact) ListDomainsRequest(input *ListDomainsInput) (req *request.Request, output *ListDomainsOutput) { op := &request.Operation{ - Name: opListPackageVersionDependencies, + Name: opListDomains, HTTPMethod: "POST", - HTTPPath: "/v1/package/version/dependencies", + HTTPPath: "/v1/domains", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &ListPackageVersionDependenciesInput{} + input = &ListDomainsInput{} } - output = &ListPackageVersionDependenciesOutput{} + output = &ListDomainsOutput{} req = c.newRequest(op, input, output) return } -// ListPackageVersionDependencies API operation for CodeArtifact. +// ListDomains API operation for CodeArtifact. // -// Returns the direct dependencies for a package version. The dependencies are -// returned as PackageDependency (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageDependency.html) -// objects. CodeArtifact extracts the dependencies for a package version from -// the metadata file for the package format (for example, the package.json file -// for npm packages and the pom.xml file for Maven). Any package version dependencies -// that are not listed in the configuration file are not returned. +// Returns a list of DomainSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionDescription.html) +// objects for all domains owned by the Amazon Web Services account that makes +// this call. Each returned DomainSummary object contains information about +// a domain. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation ListPackageVersionDependencies for usage and error information. +// API operation ListDomains for usage and error information. // // Returned Error Types: // @@ -2565,10 +2979,6 @@ func (c *CodeArtifact) ListPackageVersionDependenciesRequest(input *ListPackageV // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // -// - ResourceNotFoundException -// The operation did not succeed because the resource requested is not found -// in the service. -// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -2576,58 +2986,109 @@ func (c *CodeArtifact) ListPackageVersionDependenciesRequest(input *ListPackageV // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersionDependencies -func (c *CodeArtifact) ListPackageVersionDependencies(input *ListPackageVersionDependenciesInput) (*ListPackageVersionDependenciesOutput, error) { - req, out := c.ListPackageVersionDependenciesRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListDomains +func (c *CodeArtifact) ListDomains(input *ListDomainsInput) (*ListDomainsOutput, error) { + req, out := c.ListDomainsRequest(input) return out, req.Send() } -// ListPackageVersionDependenciesWithContext is the same as ListPackageVersionDependencies with the addition of +// ListDomainsWithContext is the same as ListDomains with the addition of // the ability to pass a context and additional request options. // -// See ListPackageVersionDependencies for details on how to use this API operation. +// See ListDomains for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListPackageVersionDependenciesWithContext(ctx aws.Context, input *ListPackageVersionDependenciesInput, opts ...request.Option) (*ListPackageVersionDependenciesOutput, error) { - req, out := c.ListPackageVersionDependenciesRequest(input) +func (c *CodeArtifact) ListDomainsWithContext(ctx aws.Context, input *ListDomainsInput, opts ...request.Option) (*ListDomainsOutput, error) { + req, out := c.ListDomainsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opListPackageVersions = "ListPackageVersions" +// ListDomainsPages iterates over the pages of a ListDomains operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListDomains method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListDomains operation. +// pageNum := 0 +// err := client.ListDomainsPages(params, +// func(page *codeartifact.ListDomainsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *CodeArtifact) ListDomainsPages(input *ListDomainsInput, fn func(*ListDomainsOutput, bool) bool) error { + return c.ListDomainsPagesWithContext(aws.BackgroundContext(), input, fn) +} -// ListPackageVersionsRequest generates a "aws/request.Request" representing the -// client's request for the ListPackageVersions operation. The "output" return +// ListDomainsPagesWithContext same as ListDomainsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) ListDomainsPagesWithContext(ctx aws.Context, input *ListDomainsInput, fn func(*ListDomainsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListDomainsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListDomainsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListDomainsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListPackageGroups = "ListPackageGroups" + +// ListPackageGroupsRequest generates a "aws/request.Request" representing the +// client's request for the ListPackageGroups operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListPackageVersions for more information on using the ListPackageVersions +// See ListPackageGroups for more information on using the ListPackageGroups // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListPackageVersionsRequest method. -// req, resp := client.ListPackageVersionsRequest(params) +// // Example sending a request using the ListPackageGroupsRequest method. +// req, resp := client.ListPackageGroupsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersions -func (c *CodeArtifact) ListPackageVersionsRequest(input *ListPackageVersionsInput) (req *request.Request, output *ListPackageVersionsOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageGroups +func (c *CodeArtifact) ListPackageGroupsRequest(input *ListPackageGroupsInput) (req *request.Request, output *ListPackageGroupsOutput) { op := &request.Operation{ - Name: opListPackageVersions, + Name: opListPackageGroups, HTTPMethod: "POST", - HTTPPath: "/v1/package/versions", + HTTPPath: "/v1/package-groups", Paginator: &request.Paginator{ InputTokens: []string{"nextToken"}, OutputTokens: []string{"nextToken"}, @@ -2637,27 +3098,24 @@ func (c *CodeArtifact) ListPackageVersionsRequest(input *ListPackageVersionsInpu } if input == nil { - input = &ListPackageVersionsInput{} + input = &ListPackageGroupsInput{} } - output = &ListPackageVersionsOutput{} + output = &ListPackageGroupsOutput{} req = c.newRequest(op, input, output) return } -// ListPackageVersions API operation for CodeArtifact. +// ListPackageGroups API operation for CodeArtifact. // -// Returns a list of PackageVersionSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionSummary.html) -// objects for package versions in a repository that match the request parameters. -// Package versions of all statuses will be returned by default when calling -// list-package-versions with no --status parameter. +// Returns a list of package groups in the requested domain. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation ListPackageVersions for usage and error information. +// API operation ListPackageGroups for usage and error information. // // Returned Error Types: // @@ -2667,10 +3125,6 @@ func (c *CodeArtifact) ListPackageVersionsRequest(input *ListPackageVersionsInpu // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // -// - ResourceNotFoundException -// The operation did not succeed because the resource requested is not found -// in the service. -// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -2678,64 +3132,68 @@ func (c *CodeArtifact) ListPackageVersionsRequest(input *ListPackageVersionsInpu // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersions -func (c *CodeArtifact) ListPackageVersions(input *ListPackageVersionsInput) (*ListPackageVersionsOutput, error) { - req, out := c.ListPackageVersionsRequest(input) +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageGroups +func (c *CodeArtifact) ListPackageGroups(input *ListPackageGroupsInput) (*ListPackageGroupsOutput, error) { + req, out := c.ListPackageGroupsRequest(input) return out, req.Send() } -// ListPackageVersionsWithContext is the same as ListPackageVersions with the addition of +// ListPackageGroupsWithContext is the same as ListPackageGroups with the addition of // the ability to pass a context and additional request options. // -// See ListPackageVersions for details on how to use this API operation. +// See ListPackageGroups for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListPackageVersionsWithContext(ctx aws.Context, input *ListPackageVersionsInput, opts ...request.Option) (*ListPackageVersionsOutput, error) { - req, out := c.ListPackageVersionsRequest(input) +func (c *CodeArtifact) ListPackageGroupsWithContext(ctx aws.Context, input *ListPackageGroupsInput, opts ...request.Option) (*ListPackageGroupsOutput, error) { + req, out := c.ListPackageGroupsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListPackageVersionsPages iterates over the pages of a ListPackageVersions operation, +// ListPackageGroupsPages iterates over the pages of a ListPackageGroups operation, // calling the "fn" function with the response data for each page. To stop // iterating, return false from the fn function. // -// See ListPackageVersions method for more information on how to use this operation. +// See ListPackageGroups method for more information on how to use this operation. // // Note: This operation can generate multiple requests to a service. // -// // Example iterating over at most 3 pages of a ListPackageVersions operation. +// // Example iterating over at most 3 pages of a ListPackageGroups operation. // pageNum := 0 -// err := client.ListPackageVersionsPages(params, -// func(page *codeartifact.ListPackageVersionsOutput, lastPage bool) bool { +// err := client.ListPackageGroupsPages(params, +// func(page *codeartifact.ListPackageGroupsOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 // }) -func (c *CodeArtifact) ListPackageVersionsPages(input *ListPackageVersionsInput, fn func(*ListPackageVersionsOutput, bool) bool) error { - return c.ListPackageVersionsPagesWithContext(aws.BackgroundContext(), input, fn) +func (c *CodeArtifact) ListPackageGroupsPages(input *ListPackageGroupsInput, fn func(*ListPackageGroupsOutput, bool) bool) error { + return c.ListPackageGroupsPagesWithContext(aws.BackgroundContext(), input, fn) } -// ListPackageVersionsPagesWithContext same as ListPackageVersionsPages except +// ListPackageGroupsPagesWithContext same as ListPackageGroupsPages except // it takes a Context and allows setting request options on the pages. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListPackageVersionsPagesWithContext(ctx aws.Context, input *ListPackageVersionsInput, fn func(*ListPackageVersionsOutput, bool) bool, opts ...request.Option) error { +func (c *CodeArtifact) ListPackageGroupsPagesWithContext(ctx aws.Context, input *ListPackageGroupsInput, fn func(*ListPackageGroupsOutput, bool) bool, opts ...request.Option) error { p := request.Pagination{ NewRequest: func() (*request.Request, error) { - var inCpy *ListPackageVersionsInput + var inCpy *ListPackageGroupsInput if input != nil { tmp := *input inCpy = &tmp } - req, _ := c.ListPackageVersionsRequest(inCpy) + req, _ := c.ListPackageGroupsRequest(inCpy) req.SetContext(ctx) req.ApplyOptions(opts...) return req, nil @@ -2743,7 +3201,7 @@ func (c *CodeArtifact) ListPackageVersionsPagesWithContext(ctx aws.Context, inpu } for p.Next() { - if !fn(p.Page().(*ListPackageVersionsOutput), !p.HasNextPage()) { + if !fn(p.Page().(*ListPackageGroupsOutput), !p.HasNextPage()) { break } } @@ -2751,36 +3209,36 @@ func (c *CodeArtifact) ListPackageVersionsPagesWithContext(ctx aws.Context, inpu return p.Err() } -const opListPackages = "ListPackages" +const opListPackageVersionAssets = "ListPackageVersionAssets" -// ListPackagesRequest generates a "aws/request.Request" representing the -// client's request for the ListPackages operation. The "output" return +// ListPackageVersionAssetsRequest generates a "aws/request.Request" representing the +// client's request for the ListPackageVersionAssets operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListPackages for more information on using the ListPackages +// See ListPackageVersionAssets for more information on using the ListPackageVersionAssets // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListPackagesRequest method. -// req, resp := client.ListPackagesRequest(params) +// // Example sending a request using the ListPackageVersionAssetsRequest method. +// req, resp := client.ListPackageVersionAssetsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackages -func (c *CodeArtifact) ListPackagesRequest(input *ListPackagesInput) (req *request.Request, output *ListPackagesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersionAssets +func (c *CodeArtifact) ListPackageVersionAssetsRequest(input *ListPackageVersionAssetsInput) (req *request.Request, output *ListPackageVersionAssetsOutput) { op := &request.Operation{ - Name: opListPackages, + Name: opListPackageVersionAssets, HTTPMethod: "POST", - HTTPPath: "/v1/packages", + HTTPPath: "/v1/package/version/assets", Paginator: &request.Paginator{ InputTokens: []string{"nextToken"}, OutputTokens: []string{"nextToken"}, @@ -2790,25 +3248,25 @@ func (c *CodeArtifact) ListPackagesRequest(input *ListPackagesInput) (req *reque } if input == nil { - input = &ListPackagesInput{} + input = &ListPackageVersionAssetsInput{} } - output = &ListPackagesOutput{} + output = &ListPackageVersionAssetsOutput{} req = c.newRequest(op, input, output) return } -// ListPackages API operation for CodeArtifact. +// ListPackageVersionAssets API operation for CodeArtifact. // -// Returns a list of PackageSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageSummary.html) -// objects for packages in a repository that match the request parameters. +// Returns a list of AssetSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_AssetSummary.html) +// objects for assets in a package version. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation ListPackages for usage and error information. +// API operation ListPackageVersionAssets for usage and error information. // // Returned Error Types: // @@ -2829,64 +3287,64 @@ func (c *CodeArtifact) ListPackagesRequest(input *ListPackagesInput) (req *reque // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackages -func (c *CodeArtifact) ListPackages(input *ListPackagesInput) (*ListPackagesOutput, error) { - req, out := c.ListPackagesRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersionAssets +func (c *CodeArtifact) ListPackageVersionAssets(input *ListPackageVersionAssetsInput) (*ListPackageVersionAssetsOutput, error) { + req, out := c.ListPackageVersionAssetsRequest(input) return out, req.Send() } -// ListPackagesWithContext is the same as ListPackages with the addition of +// ListPackageVersionAssetsWithContext is the same as ListPackageVersionAssets with the addition of // the ability to pass a context and additional request options. // -// See ListPackages for details on how to use this API operation. +// See ListPackageVersionAssets for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListPackagesWithContext(ctx aws.Context, input *ListPackagesInput, opts ...request.Option) (*ListPackagesOutput, error) { - req, out := c.ListPackagesRequest(input) +func (c *CodeArtifact) ListPackageVersionAssetsWithContext(ctx aws.Context, input *ListPackageVersionAssetsInput, opts ...request.Option) (*ListPackageVersionAssetsOutput, error) { + req, out := c.ListPackageVersionAssetsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListPackagesPages iterates over the pages of a ListPackages operation, +// ListPackageVersionAssetsPages iterates over the pages of a ListPackageVersionAssets operation, // calling the "fn" function with the response data for each page. To stop // iterating, return false from the fn function. // -// See ListPackages method for more information on how to use this operation. +// See ListPackageVersionAssets method for more information on how to use this operation. // // Note: This operation can generate multiple requests to a service. // -// // Example iterating over at most 3 pages of a ListPackages operation. +// // Example iterating over at most 3 pages of a ListPackageVersionAssets operation. // pageNum := 0 -// err := client.ListPackagesPages(params, -// func(page *codeartifact.ListPackagesOutput, lastPage bool) bool { +// err := client.ListPackageVersionAssetsPages(params, +// func(page *codeartifact.ListPackageVersionAssetsOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 // }) -func (c *CodeArtifact) ListPackagesPages(input *ListPackagesInput, fn func(*ListPackagesOutput, bool) bool) error { - return c.ListPackagesPagesWithContext(aws.BackgroundContext(), input, fn) +func (c *CodeArtifact) ListPackageVersionAssetsPages(input *ListPackageVersionAssetsInput, fn func(*ListPackageVersionAssetsOutput, bool) bool) error { + return c.ListPackageVersionAssetsPagesWithContext(aws.BackgroundContext(), input, fn) } -// ListPackagesPagesWithContext same as ListPackagesPages except +// ListPackageVersionAssetsPagesWithContext same as ListPackageVersionAssetsPages except // it takes a Context and allows setting request options on the pages. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListPackagesPagesWithContext(ctx aws.Context, input *ListPackagesInput, fn func(*ListPackagesOutput, bool) bool, opts ...request.Option) error { +func (c *CodeArtifact) ListPackageVersionAssetsPagesWithContext(ctx aws.Context, input *ListPackageVersionAssetsInput, fn func(*ListPackageVersionAssetsOutput, bool) bool, opts ...request.Option) error { p := request.Pagination{ NewRequest: func() (*request.Request, error) { - var inCpy *ListPackagesInput + var inCpy *ListPackageVersionAssetsInput if input != nil { tmp := *input inCpy = &tmp } - req, _ := c.ListPackagesRequest(inCpy) + req, _ := c.ListPackageVersionAssetsRequest(inCpy) req.SetContext(ctx) req.ApplyOptions(opts...) return req, nil @@ -2894,7 +3352,7 @@ func (c *CodeArtifact) ListPackagesPagesWithContext(ctx aws.Context, input *List } for p.Next() { - if !fn(p.Page().(*ListPackagesOutput), !p.HasNextPage()) { + if !fn(p.Page().(*ListPackageVersionAssetsOutput), !p.HasNextPage()) { break } } @@ -2902,65 +3360,62 @@ func (c *CodeArtifact) ListPackagesPagesWithContext(ctx aws.Context, input *List return p.Err() } -const opListRepositories = "ListRepositories" +const opListPackageVersionDependencies = "ListPackageVersionDependencies" -// ListRepositoriesRequest generates a "aws/request.Request" representing the -// client's request for the ListRepositories operation. The "output" return +// ListPackageVersionDependenciesRequest generates a "aws/request.Request" representing the +// client's request for the ListPackageVersionDependencies operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListRepositories for more information on using the ListRepositories +// See ListPackageVersionDependencies for more information on using the ListPackageVersionDependencies // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListRepositoriesRequest method. -// req, resp := client.ListRepositoriesRequest(params) +// // Example sending a request using the ListPackageVersionDependenciesRequest method. +// req, resp := client.ListPackageVersionDependenciesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListRepositories -func (c *CodeArtifact) ListRepositoriesRequest(input *ListRepositoriesInput) (req *request.Request, output *ListRepositoriesOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersionDependencies +func (c *CodeArtifact) ListPackageVersionDependenciesRequest(input *ListPackageVersionDependenciesInput) (req *request.Request, output *ListPackageVersionDependenciesOutput) { op := &request.Operation{ - Name: opListRepositories, + Name: opListPackageVersionDependencies, HTTPMethod: "POST", - HTTPPath: "/v1/repositories", - Paginator: &request.Paginator{ - InputTokens: []string{"nextToken"}, - OutputTokens: []string{"nextToken"}, - LimitToken: "maxResults", - TruncationToken: "", - }, + HTTPPath: "/v1/package/version/dependencies", } if input == nil { - input = &ListRepositoriesInput{} + input = &ListPackageVersionDependenciesInput{} } - output = &ListRepositoriesOutput{} + output = &ListPackageVersionDependenciesOutput{} req = c.newRequest(op, input, output) return } -// ListRepositories API operation for CodeArtifact. +// ListPackageVersionDependencies API operation for CodeArtifact. // -// Returns a list of RepositorySummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_RepositorySummary.html) -// objects. Each RepositorySummary contains information about a repository in -// the specified Amazon Web Services account and that matches the input parameters. +// Returns the direct dependencies for a package version. The dependencies are +// returned as PackageDependency (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageDependency.html) +// objects. CodeArtifact extracts the dependencies for a package version from +// the metadata file for the package format (for example, the package.json file +// for npm packages and the pom.xml file for Maven). Any package version dependencies +// that are not listed in the configuration file are not returned. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation ListRepositories for usage and error information. +// API operation ListPackageVersionDependencies for usage and error information. // // Returned Error Types: // @@ -2970,6 +3425,10 @@ func (c *CodeArtifact) ListRepositoriesRequest(input *ListRepositoriesInput) (re // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -2977,109 +3436,58 @@ func (c *CodeArtifact) ListRepositoriesRequest(input *ListRepositoriesInput) (re // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListRepositories -func (c *CodeArtifact) ListRepositories(input *ListRepositoriesInput) (*ListRepositoriesOutput, error) { - req, out := c.ListRepositoriesRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersionDependencies +func (c *CodeArtifact) ListPackageVersionDependencies(input *ListPackageVersionDependenciesInput) (*ListPackageVersionDependenciesOutput, error) { + req, out := c.ListPackageVersionDependenciesRequest(input) return out, req.Send() } -// ListRepositoriesWithContext is the same as ListRepositories with the addition of +// ListPackageVersionDependenciesWithContext is the same as ListPackageVersionDependencies with the addition of // the ability to pass a context and additional request options. // -// See ListRepositories for details on how to use this API operation. +// See ListPackageVersionDependencies for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListRepositoriesWithContext(ctx aws.Context, input *ListRepositoriesInput, opts ...request.Option) (*ListRepositoriesOutput, error) { - req, out := c.ListRepositoriesRequest(input) +func (c *CodeArtifact) ListPackageVersionDependenciesWithContext(ctx aws.Context, input *ListPackageVersionDependenciesInput, opts ...request.Option) (*ListPackageVersionDependenciesOutput, error) { + req, out := c.ListPackageVersionDependenciesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListRepositoriesPages iterates over the pages of a ListRepositories operation, -// calling the "fn" function with the response data for each page. To stop -// iterating, return false from the fn function. -// -// See ListRepositories method for more information on how to use this operation. +const opListPackageVersions = "ListPackageVersions" + +// ListPackageVersionsRequest generates a "aws/request.Request" representing the +// client's request for the ListPackageVersions operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. // -// Note: This operation can generate multiple requests to a service. +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. // -// // Example iterating over at most 3 pages of a ListRepositories operation. -// pageNum := 0 -// err := client.ListRepositoriesPages(params, -// func(page *codeartifact.ListRepositoriesOutput, lastPage bool) bool { -// pageNum++ -// fmt.Println(page) -// return pageNum <= 3 -// }) -func (c *CodeArtifact) ListRepositoriesPages(input *ListRepositoriesInput, fn func(*ListRepositoriesOutput, bool) bool) error { - return c.ListRepositoriesPagesWithContext(aws.BackgroundContext(), input, fn) -} - -// ListRepositoriesPagesWithContext same as ListRepositoriesPages except -// it takes a Context and allows setting request options on the pages. -// -// The context must be non-nil and will be used for request cancellation. If -// the context is nil a panic will occur. In the future the SDK may create -// sub-contexts for http.Requests. See https://golang.org/pkg/context/ -// for more information on using Contexts. -func (c *CodeArtifact) ListRepositoriesPagesWithContext(ctx aws.Context, input *ListRepositoriesInput, fn func(*ListRepositoriesOutput, bool) bool, opts ...request.Option) error { - p := request.Pagination{ - NewRequest: func() (*request.Request, error) { - var inCpy *ListRepositoriesInput - if input != nil { - tmp := *input - inCpy = &tmp - } - req, _ := c.ListRepositoriesRequest(inCpy) - req.SetContext(ctx) - req.ApplyOptions(opts...) - return req, nil - }, - } - - for p.Next() { - if !fn(p.Page().(*ListRepositoriesOutput), !p.HasNextPage()) { - break - } - } - - return p.Err() -} - -const opListRepositoriesInDomain = "ListRepositoriesInDomain" - -// ListRepositoriesInDomainRequest generates a "aws/request.Request" representing the -// client's request for the ListRepositoriesInDomain operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. -// -// Use "Send" method on the returned Request to send the API call to the service. -// the "output" return value is not valid until after Send returns without error. -// -// See ListRepositoriesInDomain for more information on using the ListRepositoriesInDomain -// API call, and error handling. +// See ListPackageVersions for more information on using the ListPackageVersions +// API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListRepositoriesInDomainRequest method. -// req, resp := client.ListRepositoriesInDomainRequest(params) +// // Example sending a request using the ListPackageVersionsRequest method. +// req, resp := client.ListPackageVersionsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListRepositoriesInDomain -func (c *CodeArtifact) ListRepositoriesInDomainRequest(input *ListRepositoriesInDomainInput) (req *request.Request, output *ListRepositoriesInDomainOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersions +func (c *CodeArtifact) ListPackageVersionsRequest(input *ListPackageVersionsInput) (req *request.Request, output *ListPackageVersionsOutput) { op := &request.Operation{ - Name: opListRepositoriesInDomain, + Name: opListPackageVersions, HTTPMethod: "POST", - HTTPPath: "/v1/domain/repositories", + HTTPPath: "/v1/package/versions", Paginator: &request.Paginator{ InputTokens: []string{"nextToken"}, OutputTokens: []string{"nextToken"}, @@ -3089,26 +3497,27 @@ func (c *CodeArtifact) ListRepositoriesInDomainRequest(input *ListRepositoriesIn } if input == nil { - input = &ListRepositoriesInDomainInput{} + input = &ListPackageVersionsInput{} } - output = &ListRepositoriesInDomainOutput{} + output = &ListPackageVersionsOutput{} req = c.newRequest(op, input, output) return } -// ListRepositoriesInDomain API operation for CodeArtifact. +// ListPackageVersions API operation for CodeArtifact. // -// Returns a list of RepositorySummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_RepositorySummary.html) -// objects. Each RepositorySummary contains information about a repository in -// the specified domain and that matches the input parameters. +// Returns a list of PackageVersionSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionSummary.html) +// objects for package versions in a repository that match the request parameters. +// Package versions of all statuses will be returned by default when calling +// list-package-versions with no --status parameter. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation ListRepositoriesInDomain for usage and error information. +// API operation ListPackageVersions for usage and error information. // // Returned Error Types: // @@ -3129,64 +3538,64 @@ func (c *CodeArtifact) ListRepositoriesInDomainRequest(input *ListRepositoriesIn // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListRepositoriesInDomain -func (c *CodeArtifact) ListRepositoriesInDomain(input *ListRepositoriesInDomainInput) (*ListRepositoriesInDomainOutput, error) { - req, out := c.ListRepositoriesInDomainRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackageVersions +func (c *CodeArtifact) ListPackageVersions(input *ListPackageVersionsInput) (*ListPackageVersionsOutput, error) { + req, out := c.ListPackageVersionsRequest(input) return out, req.Send() } -// ListRepositoriesInDomainWithContext is the same as ListRepositoriesInDomain with the addition of +// ListPackageVersionsWithContext is the same as ListPackageVersions with the addition of // the ability to pass a context and additional request options. // -// See ListRepositoriesInDomain for details on how to use this API operation. +// See ListPackageVersions for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListRepositoriesInDomainWithContext(ctx aws.Context, input *ListRepositoriesInDomainInput, opts ...request.Option) (*ListRepositoriesInDomainOutput, error) { - req, out := c.ListRepositoriesInDomainRequest(input) +func (c *CodeArtifact) ListPackageVersionsWithContext(ctx aws.Context, input *ListPackageVersionsInput, opts ...request.Option) (*ListPackageVersionsOutput, error) { + req, out := c.ListPackageVersionsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// ListRepositoriesInDomainPages iterates over the pages of a ListRepositoriesInDomain operation, +// ListPackageVersionsPages iterates over the pages of a ListPackageVersions operation, // calling the "fn" function with the response data for each page. To stop // iterating, return false from the fn function. // -// See ListRepositoriesInDomain method for more information on how to use this operation. +// See ListPackageVersions method for more information on how to use this operation. // // Note: This operation can generate multiple requests to a service. // -// // Example iterating over at most 3 pages of a ListRepositoriesInDomain operation. +// // Example iterating over at most 3 pages of a ListPackageVersions operation. // pageNum := 0 -// err := client.ListRepositoriesInDomainPages(params, -// func(page *codeartifact.ListRepositoriesInDomainOutput, lastPage bool) bool { +// err := client.ListPackageVersionsPages(params, +// func(page *codeartifact.ListPackageVersionsOutput, lastPage bool) bool { // pageNum++ // fmt.Println(page) // return pageNum <= 3 // }) -func (c *CodeArtifact) ListRepositoriesInDomainPages(input *ListRepositoriesInDomainInput, fn func(*ListRepositoriesInDomainOutput, bool) bool) error { - return c.ListRepositoriesInDomainPagesWithContext(aws.BackgroundContext(), input, fn) +func (c *CodeArtifact) ListPackageVersionsPages(input *ListPackageVersionsInput, fn func(*ListPackageVersionsOutput, bool) bool) error { + return c.ListPackageVersionsPagesWithContext(aws.BackgroundContext(), input, fn) } -// ListRepositoriesInDomainPagesWithContext same as ListRepositoriesInDomainPages except +// ListPackageVersionsPagesWithContext same as ListPackageVersionsPages except // it takes a Context and allows setting request options on the pages. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListRepositoriesInDomainPagesWithContext(ctx aws.Context, input *ListRepositoriesInDomainInput, fn func(*ListRepositoriesInDomainOutput, bool) bool, opts ...request.Option) error { +func (c *CodeArtifact) ListPackageVersionsPagesWithContext(ctx aws.Context, input *ListPackageVersionsInput, fn func(*ListPackageVersionsOutput, bool) bool, opts ...request.Option) error { p := request.Pagination{ NewRequest: func() (*request.Request, error) { - var inCpy *ListRepositoriesInDomainInput + var inCpy *ListPackageVersionsInput if input != nil { tmp := *input inCpy = &tmp } - req, _ := c.ListRepositoriesInDomainRequest(inCpy) + req, _ := c.ListPackageVersionsRequest(inCpy) req.SetContext(ctx) req.ApplyOptions(opts...) return req, nil @@ -3194,7 +3603,7 @@ func (c *CodeArtifact) ListRepositoriesInDomainPagesWithContext(ctx aws.Context, } for p.Next() { - if !fn(p.Page().(*ListRepositoriesInDomainOutput), !p.HasNextPage()) { + if !fn(p.Page().(*ListPackageVersionsOutput), !p.HasNextPage()) { break } } @@ -3202,64 +3611,73 @@ func (c *CodeArtifact) ListRepositoriesInDomainPagesWithContext(ctx aws.Context, return p.Err() } -const opListTagsForResource = "ListTagsForResource" +const opListPackages = "ListPackages" -// ListTagsForResourceRequest generates a "aws/request.Request" representing the -// client's request for the ListTagsForResource operation. The "output" return +// ListPackagesRequest generates a "aws/request.Request" representing the +// client's request for the ListPackages operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See ListTagsForResource for more information on using the ListTagsForResource +// See ListPackages for more information on using the ListPackages // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the ListTagsForResourceRequest method. -// req, resp := client.ListTagsForResourceRequest(params) +// // Example sending a request using the ListPackagesRequest method. +// req, resp := client.ListPackagesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListTagsForResource -func (c *CodeArtifact) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackages +func (c *CodeArtifact) ListPackagesRequest(input *ListPackagesInput) (req *request.Request, output *ListPackagesOutput) { op := &request.Operation{ - Name: opListTagsForResource, + Name: opListPackages, HTTPMethod: "POST", - HTTPPath: "/v1/tags", + HTTPPath: "/v1/packages", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &ListTagsForResourceInput{} + input = &ListPackagesInput{} } - output = &ListTagsForResourceOutput{} + output = &ListPackagesOutput{} req = c.newRequest(op, input, output) return } -// ListTagsForResource API operation for CodeArtifact. +// ListPackages API operation for CodeArtifact. // -// Gets information about Amazon Web Services tags for a specified Amazon Resource -// Name (ARN) in CodeArtifact. +// Returns a list of PackageSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageSummary.html) +// objects for packages in a repository that match the request parameters. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation ListTagsForResource for usage and error information. +// API operation ListPackages for usage and error information. // // Returned Error Types: // // - AccessDeniedException // The operation did not succeed because of an unauthorized access attempt. // +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// // - ResourceNotFoundException // The operation did not succeed because the resource requested is not found // in the service. @@ -3271,112 +3689,147 @@ func (c *CodeArtifact) ListTagsForResourceRequest(input *ListTagsForResourceInpu // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListTagsForResource -func (c *CodeArtifact) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { - req, out := c.ListTagsForResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListPackages +func (c *CodeArtifact) ListPackages(input *ListPackagesInput) (*ListPackagesOutput, error) { + req, out := c.ListPackagesRequest(input) return out, req.Send() } -// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of +// ListPackagesWithContext is the same as ListPackages with the addition of // the ability to pass a context and additional request options. // -// See ListTagsForResource for details on how to use this API operation. +// See ListPackages for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { - req, out := c.ListTagsForResourceRequest(input) +func (c *CodeArtifact) ListPackagesWithContext(ctx aws.Context, input *ListPackagesInput, opts ...request.Option) (*ListPackagesOutput, error) { + req, out := c.ListPackagesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPublishPackageVersion = "PublishPackageVersion" +// ListPackagesPages iterates over the pages of a ListPackages operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListPackages method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListPackages operation. +// pageNum := 0 +// err := client.ListPackagesPages(params, +// func(page *codeartifact.ListPackagesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *CodeArtifact) ListPackagesPages(input *ListPackagesInput, fn func(*ListPackagesOutput, bool) bool) error { + return c.ListPackagesPagesWithContext(aws.BackgroundContext(), input, fn) +} -// PublishPackageVersionRequest generates a "aws/request.Request" representing the -// client's request for the PublishPackageVersion operation. The "output" return +// ListPackagesPagesWithContext same as ListPackagesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) ListPackagesPagesWithContext(ctx aws.Context, input *ListPackagesInput, fn func(*ListPackagesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListPackagesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListPackagesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListPackagesOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListRepositories = "ListRepositories" + +// ListRepositoriesRequest generates a "aws/request.Request" representing the +// client's request for the ListRepositories operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PublishPackageVersion for more information on using the PublishPackageVersion +// See ListRepositories for more information on using the ListRepositories // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the PublishPackageVersionRequest method. -// req, resp := client.PublishPackageVersionRequest(params) +// // Example sending a request using the ListRepositoriesRequest method. +// req, resp := client.ListRepositoriesRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PublishPackageVersion -func (c *CodeArtifact) PublishPackageVersionRequest(input *PublishPackageVersionInput) (req *request.Request, output *PublishPackageVersionOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListRepositories +func (c *CodeArtifact) ListRepositoriesRequest(input *ListRepositoriesInput) (req *request.Request, output *ListRepositoriesOutput) { op := &request.Operation{ - Name: opPublishPackageVersion, + Name: opListRepositories, HTTPMethod: "POST", - HTTPPath: "/v1/package/version/publish", + HTTPPath: "/v1/repositories", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &PublishPackageVersionInput{} + input = &ListRepositoriesInput{} } - output = &PublishPackageVersionOutput{} + output = &ListRepositoriesOutput{} req = c.newRequest(op, input, output) return } -// PublishPackageVersion API operation for CodeArtifact. +// ListRepositories API operation for CodeArtifact. // -// 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 -// (https://docs.aws.amazon.com/codeartifact/latest/ug/packages-overview.html#package-version-status.html#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 (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_UpdatePackageVersionsStatus.html). -// 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 (https://docs.aws.amazon.com/codeartifact/latest/ug/using-generic.html) -// in the CodeArtifact User Guide. +// Returns a list of RepositorySummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_RepositorySummary.html) +// objects. Each RepositorySummary contains information about a repository in +// the specified Amazon Web Services account and that matches the input parameters. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation PublishPackageVersion for usage and error information. +// API operation ListRepositories for usage and error information. // // Returned Error Types: // // - AccessDeniedException // The operation did not succeed because of an unauthorized access attempt. // -// - ConflictException -// The operation did not succeed because prerequisites are not met. -// // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // -// - ResourceNotFoundException -// The operation did not succeed because the resource requested is not found -// in the service. -// -// - ServiceQuotaExceededException -// The operation did not succeed because it would have exceeded a service limit -// for your account. -// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -3384,93 +3837,144 @@ func (c *CodeArtifact) PublishPackageVersionRequest(input *PublishPackageVersion // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PublishPackageVersion -func (c *CodeArtifact) PublishPackageVersion(input *PublishPackageVersionInput) (*PublishPackageVersionOutput, error) { - req, out := c.PublishPackageVersionRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListRepositories +func (c *CodeArtifact) ListRepositories(input *ListRepositoriesInput) (*ListRepositoriesOutput, error) { + req, out := c.ListRepositoriesRequest(input) return out, req.Send() } -// PublishPackageVersionWithContext is the same as PublishPackageVersion with the addition of +// ListRepositoriesWithContext is the same as ListRepositories with the addition of // the ability to pass a context and additional request options. // -// See PublishPackageVersion for details on how to use this API operation. +// See ListRepositories for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) PublishPackageVersionWithContext(ctx aws.Context, input *PublishPackageVersionInput, opts ...request.Option) (*PublishPackageVersionOutput, error) { - req, out := c.PublishPackageVersionRequest(input) +func (c *CodeArtifact) ListRepositoriesWithContext(ctx aws.Context, input *ListRepositoriesInput, opts ...request.Option) (*ListRepositoriesOutput, error) { + req, out := c.ListRepositoriesRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPutDomainPermissionsPolicy = "PutDomainPermissionsPolicy" +// ListRepositoriesPages iterates over the pages of a ListRepositories operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListRepositories method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListRepositories operation. +// pageNum := 0 +// err := client.ListRepositoriesPages(params, +// func(page *codeartifact.ListRepositoriesOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *CodeArtifact) ListRepositoriesPages(input *ListRepositoriesInput, fn func(*ListRepositoriesOutput, bool) bool) error { + return c.ListRepositoriesPagesWithContext(aws.BackgroundContext(), input, fn) +} -// PutDomainPermissionsPolicyRequest generates a "aws/request.Request" representing the -// client's request for the PutDomainPermissionsPolicy operation. The "output" return +// ListRepositoriesPagesWithContext same as ListRepositoriesPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) ListRepositoriesPagesWithContext(ctx aws.Context, input *ListRepositoriesInput, fn func(*ListRepositoriesOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListRepositoriesInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListRepositoriesRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListRepositoriesOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListRepositoriesInDomain = "ListRepositoriesInDomain" + +// ListRepositoriesInDomainRequest generates a "aws/request.Request" representing the +// client's request for the ListRepositoriesInDomain operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PutDomainPermissionsPolicy for more information on using the PutDomainPermissionsPolicy +// See ListRepositoriesInDomain for more information on using the ListRepositoriesInDomain // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the PutDomainPermissionsPolicyRequest method. -// req, resp := client.PutDomainPermissionsPolicyRequest(params) +// // Example sending a request using the ListRepositoriesInDomainRequest method. +// req, resp := client.ListRepositoriesInDomainRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutDomainPermissionsPolicy -func (c *CodeArtifact) PutDomainPermissionsPolicyRequest(input *PutDomainPermissionsPolicyInput) (req *request.Request, output *PutDomainPermissionsPolicyOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListRepositoriesInDomain +func (c *CodeArtifact) ListRepositoriesInDomainRequest(input *ListRepositoriesInDomainInput) (req *request.Request, output *ListRepositoriesInDomainOutput) { op := &request.Operation{ - Name: opPutDomainPermissionsPolicy, - HTTPMethod: "PUT", - HTTPPath: "/v1/domain/permissions/policy", + Name: opListRepositoriesInDomain, + HTTPMethod: "POST", + HTTPPath: "/v1/domain/repositories", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &PutDomainPermissionsPolicyInput{} + input = &ListRepositoriesInDomainInput{} } - output = &PutDomainPermissionsPolicyOutput{} + output = &ListRepositoriesInDomainOutput{} req = c.newRequest(op, input, output) return } -// PutDomainPermissionsPolicy API operation for CodeArtifact. -// -// Sets a resource policy on a domain that specifies permissions to access it. +// ListRepositoriesInDomain API operation for CodeArtifact. // -// When you call PutDomainPermissionsPolicy, the resource policy on the domain -// is ignored when evaluting permissions. This ensures that the owner of a domain -// cannot lock themselves out of the domain, which would prevent them from being -// able to update the resource policy. +// Returns a list of RepositorySummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_RepositorySummary.html) +// objects. Each RepositorySummary contains information about a repository in +// the specified domain and that matches the input parameters. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation PutDomainPermissionsPolicy for usage and error information. +// API operation ListRepositoriesInDomain for usage and error information. // // Returned Error Types: // // - AccessDeniedException // The operation did not succeed because of an unauthorized access attempt. // -// - ConflictException -// The operation did not succeed because prerequisites are not met. -// // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // @@ -3478,10 +3982,6 @@ func (c *CodeArtifact) PutDomainPermissionsPolicyRequest(input *PutDomainPermiss // The operation did not succeed because the resource requested is not found // in the service. // -// - ServiceQuotaExceededException -// The operation did not succeed because it would have exceeded a service limit -// for your account. -// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -3489,95 +3989,140 @@ func (c *CodeArtifact) PutDomainPermissionsPolicyRequest(input *PutDomainPermiss // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutDomainPermissionsPolicy -func (c *CodeArtifact) PutDomainPermissionsPolicy(input *PutDomainPermissionsPolicyInput) (*PutDomainPermissionsPolicyOutput, error) { - req, out := c.PutDomainPermissionsPolicyRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListRepositoriesInDomain +func (c *CodeArtifact) ListRepositoriesInDomain(input *ListRepositoriesInDomainInput) (*ListRepositoriesInDomainOutput, error) { + req, out := c.ListRepositoriesInDomainRequest(input) return out, req.Send() } -// PutDomainPermissionsPolicyWithContext is the same as PutDomainPermissionsPolicy with the addition of +// ListRepositoriesInDomainWithContext is the same as ListRepositoriesInDomain with the addition of // the ability to pass a context and additional request options. // -// See PutDomainPermissionsPolicy for details on how to use this API operation. +// See ListRepositoriesInDomain for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) PutDomainPermissionsPolicyWithContext(ctx aws.Context, input *PutDomainPermissionsPolicyInput, opts ...request.Option) (*PutDomainPermissionsPolicyOutput, error) { - req, out := c.PutDomainPermissionsPolicyRequest(input) +func (c *CodeArtifact) ListRepositoriesInDomainWithContext(ctx aws.Context, input *ListRepositoriesInDomainInput, opts ...request.Option) (*ListRepositoriesInDomainOutput, error) { + req, out := c.ListRepositoriesInDomainRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPutPackageOriginConfiguration = "PutPackageOriginConfiguration" +// ListRepositoriesInDomainPages iterates over the pages of a ListRepositoriesInDomain operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListRepositoriesInDomain method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListRepositoriesInDomain operation. +// pageNum := 0 +// err := client.ListRepositoriesInDomainPages(params, +// func(page *codeartifact.ListRepositoriesInDomainOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *CodeArtifact) ListRepositoriesInDomainPages(input *ListRepositoriesInDomainInput, fn func(*ListRepositoriesInDomainOutput, bool) bool) error { + return c.ListRepositoriesInDomainPagesWithContext(aws.BackgroundContext(), input, fn) +} -// PutPackageOriginConfigurationRequest generates a "aws/request.Request" representing the -// client's request for the PutPackageOriginConfiguration operation. The "output" return +// ListRepositoriesInDomainPagesWithContext same as ListRepositoriesInDomainPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) ListRepositoriesInDomainPagesWithContext(ctx aws.Context, input *ListRepositoriesInDomainInput, fn func(*ListRepositoriesInDomainOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListRepositoriesInDomainInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListRepositoriesInDomainRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListRepositoriesInDomainOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListSubPackageGroups = "ListSubPackageGroups" + +// ListSubPackageGroupsRequest generates a "aws/request.Request" representing the +// client's request for the ListSubPackageGroups operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PutPackageOriginConfiguration for more information on using the PutPackageOriginConfiguration +// See ListSubPackageGroups for more information on using the ListSubPackageGroups // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the PutPackageOriginConfigurationRequest method. -// req, resp := client.PutPackageOriginConfigurationRequest(params) +// // Example sending a request using the ListSubPackageGroupsRequest method. +// req, resp := client.ListSubPackageGroupsRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutPackageOriginConfiguration -func (c *CodeArtifact) PutPackageOriginConfigurationRequest(input *PutPackageOriginConfigurationInput) (req *request.Request, output *PutPackageOriginConfigurationOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListSubPackageGroups +func (c *CodeArtifact) ListSubPackageGroupsRequest(input *ListSubPackageGroupsInput) (req *request.Request, output *ListSubPackageGroupsOutput) { op := &request.Operation{ - Name: opPutPackageOriginConfiguration, + Name: opListSubPackageGroups, HTTPMethod: "POST", - HTTPPath: "/v1/package", + HTTPPath: "/v1/package-groups/sub-groups", + Paginator: &request.Paginator{ + InputTokens: []string{"nextToken"}, + OutputTokens: []string{"nextToken"}, + LimitToken: "maxResults", + TruncationToken: "", + }, } if input == nil { - input = &PutPackageOriginConfigurationInput{} + input = &ListSubPackageGroupsInput{} } - output = &PutPackageOriginConfigurationOutput{} + output = &ListSubPackageGroupsOutput{} req = c.newRequest(op, input, output) return } -// PutPackageOriginConfiguration API operation for CodeArtifact. +// ListSubPackageGroups API operation for CodeArtifact. // -// Sets the package origin configuration for a package. +// Returns a list of direct children of the specified package group. // -// The package origin configuration determines how new versions of a package -// can be added to a repository. You can allow or block direct publishing of -// new package versions, or ingestion and retaining of new package versions -// from an external connection or upstream source. For more information about -// package origin controls and configuration, see Editing package origin controls -// (https://docs.aws.amazon.com/codeartifact/latest/ug/package-origin-controls.html) +// For information package group hierarchy, see Package group definition syntax +// and matching behavior (https://docs.aws.amazon.com/codeartifact/latest/ug/package-group-definition-syntax-matching-behavior.html) // in the CodeArtifact User Guide. // -// PutPackageOriginConfiguration can be called on a package that doesn't yet -// exist in the repository. When called on a package that does not exist, a -// package is created in the repository with no versions and the requested restrictions -// are set on the package. This can be used to preemptively block ingesting -// or retaining any versions from external connections or upstream repositories, -// or to block publishing any versions of the package into the repository before -// connecting any package managers or publishers to the repository. -// // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation PutPackageOriginConfiguration for usage and error information. +// API operation ListSubPackageGroups for usage and error information. // // Returned Error Types: // @@ -3587,10 +4132,6 @@ func (c *CodeArtifact) PutPackageOriginConfigurationRequest(input *PutPackageOri // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // -// - ResourceNotFoundException -// The operation did not succeed because the resource requested is not found -// in the service. -// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -3598,105 +4139,145 @@ func (c *CodeArtifact) PutPackageOriginConfigurationRequest(input *PutPackageOri // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutPackageOriginConfiguration -func (c *CodeArtifact) PutPackageOriginConfiguration(input *PutPackageOriginConfigurationInput) (*PutPackageOriginConfigurationOutput, error) { - req, out := c.PutPackageOriginConfigurationRequest(input) +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListSubPackageGroups +func (c *CodeArtifact) ListSubPackageGroups(input *ListSubPackageGroupsInput) (*ListSubPackageGroupsOutput, error) { + req, out := c.ListSubPackageGroupsRequest(input) return out, req.Send() } -// PutPackageOriginConfigurationWithContext is the same as PutPackageOriginConfiguration with the addition of +// ListSubPackageGroupsWithContext is the same as ListSubPackageGroups with the addition of // the ability to pass a context and additional request options. // -// See PutPackageOriginConfiguration for details on how to use this API operation. +// See ListSubPackageGroups for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) PutPackageOriginConfigurationWithContext(ctx aws.Context, input *PutPackageOriginConfigurationInput, opts ...request.Option) (*PutPackageOriginConfigurationOutput, error) { - req, out := c.PutPackageOriginConfigurationRequest(input) +func (c *CodeArtifact) ListSubPackageGroupsWithContext(ctx aws.Context, input *ListSubPackageGroupsInput, opts ...request.Option) (*ListSubPackageGroupsOutput, error) { + req, out := c.ListSubPackageGroupsRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opPutRepositoryPermissionsPolicy = "PutRepositoryPermissionsPolicy" - -// PutRepositoryPermissionsPolicyRequest generates a "aws/request.Request" representing the -// client's request for the PutRepositoryPermissionsPolicy operation. The "output" return -// value will be populated with the request's response once the request completes -// successfully. +// ListSubPackageGroupsPages iterates over the pages of a ListSubPackageGroups operation, +// calling the "fn" function with the response data for each page. To stop +// iterating, return false from the fn function. +// +// See ListSubPackageGroups method for more information on how to use this operation. +// +// Note: This operation can generate multiple requests to a service. +// +// // Example iterating over at most 3 pages of a ListSubPackageGroups operation. +// pageNum := 0 +// err := client.ListSubPackageGroupsPages(params, +// func(page *codeartifact.ListSubPackageGroupsOutput, lastPage bool) bool { +// pageNum++ +// fmt.Println(page) +// return pageNum <= 3 +// }) +func (c *CodeArtifact) ListSubPackageGroupsPages(input *ListSubPackageGroupsInput, fn func(*ListSubPackageGroupsOutput, bool) bool) error { + return c.ListSubPackageGroupsPagesWithContext(aws.BackgroundContext(), input, fn) +} + +// ListSubPackageGroupsPagesWithContext same as ListSubPackageGroupsPages except +// it takes a Context and allows setting request options on the pages. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) ListSubPackageGroupsPagesWithContext(ctx aws.Context, input *ListSubPackageGroupsInput, fn func(*ListSubPackageGroupsOutput, bool) bool, opts ...request.Option) error { + p := request.Pagination{ + NewRequest: func() (*request.Request, error) { + var inCpy *ListSubPackageGroupsInput + if input != nil { + tmp := *input + inCpy = &tmp + } + req, _ := c.ListSubPackageGroupsRequest(inCpy) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return req, nil + }, + } + + for p.Next() { + if !fn(p.Page().(*ListSubPackageGroupsOutput), !p.HasNextPage()) { + break + } + } + + return p.Err() +} + +const opListTagsForResource = "ListTagsForResource" + +// ListTagsForResourceRequest generates a "aws/request.Request" representing the +// client's request for the ListTagsForResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See PutRepositoryPermissionsPolicy for more information on using the PutRepositoryPermissionsPolicy +// See ListTagsForResource for more information on using the ListTagsForResource // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the PutRepositoryPermissionsPolicyRequest method. -// req, resp := client.PutRepositoryPermissionsPolicyRequest(params) +// // Example sending a request using the ListTagsForResourceRequest method. +// req, resp := client.ListTagsForResourceRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutRepositoryPermissionsPolicy -func (c *CodeArtifact) PutRepositoryPermissionsPolicyRequest(input *PutRepositoryPermissionsPolicyInput) (req *request.Request, output *PutRepositoryPermissionsPolicyOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListTagsForResource +func (c *CodeArtifact) ListTagsForResourceRequest(input *ListTagsForResourceInput) (req *request.Request, output *ListTagsForResourceOutput) { op := &request.Operation{ - Name: opPutRepositoryPermissionsPolicy, - HTTPMethod: "PUT", - HTTPPath: "/v1/repository/permissions/policy", + Name: opListTagsForResource, + HTTPMethod: "POST", + HTTPPath: "/v1/tags", } if input == nil { - input = &PutRepositoryPermissionsPolicyInput{} + input = &ListTagsForResourceInput{} } - output = &PutRepositoryPermissionsPolicyOutput{} + output = &ListTagsForResourceOutput{} req = c.newRequest(op, input, output) return } -// PutRepositoryPermissionsPolicy API operation for CodeArtifact. -// -// Sets the resource policy on a repository that specifies permissions to access -// it. +// ListTagsForResource API operation for CodeArtifact. // -// When you call PutRepositoryPermissionsPolicy, the resource policy on the -// repository is ignored when evaluting permissions. This ensures that the owner -// of a repository cannot lock themselves out of the repository, which would -// prevent them from being able to update the resource policy. +// Gets information about Amazon Web Services tags for a specified Amazon Resource +// Name (ARN) in CodeArtifact. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation PutRepositoryPermissionsPolicy for usage and error information. +// API operation ListTagsForResource for usage and error information. // // Returned Error Types: // // - AccessDeniedException // The operation did not succeed because of an unauthorized access attempt. // -// - ConflictException -// The operation did not succeed because prerequisites are not met. -// -// - InternalServerException -// The operation did not succeed because of an error that occurred inside CodeArtifact. -// // - ResourceNotFoundException // The operation did not succeed because the resource requested is not found // in the service. // -// - ServiceQuotaExceededException -// The operation did not succeed because it would have exceeded a service limit -// for your account. -// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -3704,86 +4285,104 @@ func (c *CodeArtifact) PutRepositoryPermissionsPolicyRequest(input *PutRepositor // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutRepositoryPermissionsPolicy -func (c *CodeArtifact) PutRepositoryPermissionsPolicy(input *PutRepositoryPermissionsPolicyInput) (*PutRepositoryPermissionsPolicyOutput, error) { - req, out := c.PutRepositoryPermissionsPolicyRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/ListTagsForResource +func (c *CodeArtifact) ListTagsForResource(input *ListTagsForResourceInput) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) return out, req.Send() } -// PutRepositoryPermissionsPolicyWithContext is the same as PutRepositoryPermissionsPolicy with the addition of +// ListTagsForResourceWithContext is the same as ListTagsForResource with the addition of // the ability to pass a context and additional request options. // -// See PutRepositoryPermissionsPolicy for details on how to use this API operation. +// See ListTagsForResource for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) PutRepositoryPermissionsPolicyWithContext(ctx aws.Context, input *PutRepositoryPermissionsPolicyInput, opts ...request.Option) (*PutRepositoryPermissionsPolicyOutput, error) { - req, out := c.PutRepositoryPermissionsPolicyRequest(input) +func (c *CodeArtifact) ListTagsForResourceWithContext(ctx aws.Context, input *ListTagsForResourceInput, opts ...request.Option) (*ListTagsForResourceOutput, error) { + req, out := c.ListTagsForResourceRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opTagResource = "TagResource" +const opPublishPackageVersion = "PublishPackageVersion" -// TagResourceRequest generates a "aws/request.Request" representing the -// client's request for the TagResource operation. The "output" return +// PublishPackageVersionRequest generates a "aws/request.Request" representing the +// client's request for the PublishPackageVersion operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See TagResource for more information on using the TagResource +// See PublishPackageVersion for more information on using the PublishPackageVersion // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the TagResourceRequest method. -// req, resp := client.TagResourceRequest(params) +// // Example sending a request using the PublishPackageVersionRequest method. +// req, resp := client.PublishPackageVersionRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/TagResource -func (c *CodeArtifact) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PublishPackageVersion +func (c *CodeArtifact) PublishPackageVersionRequest(input *PublishPackageVersionInput) (req *request.Request, output *PublishPackageVersionOutput) { op := &request.Operation{ - Name: opTagResource, + Name: opPublishPackageVersion, HTTPMethod: "POST", - HTTPPath: "/v1/tag", + HTTPPath: "/v1/package/version/publish", } if input == nil { - input = &TagResourceInput{} + input = &PublishPackageVersionInput{} } - output = &TagResourceOutput{} + output = &PublishPackageVersionOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } -// TagResource API operation for CodeArtifact. +// PublishPackageVersion API operation for CodeArtifact. // -// Adds or updates tags for a resource in CodeArtifact. +// 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 +// (https://docs.aws.amazon.com/codeartifact/latest/ug/packages-overview.html#package-version-status.html#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 (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_UpdatePackageVersionsStatus.html). +// 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 (https://docs.aws.amazon.com/codeartifact/latest/ug/using-generic.html) +// in the CodeArtifact User Guide. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation TagResource for usage and error information. +// API operation PublishPackageVersion for usage and error information. // // Returned Error Types: // // - AccessDeniedException // The operation did not succeed because of an unauthorized access attempt. // +// - ConflictException +// The operation did not succeed because prerequisites are not met. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// // - ResourceNotFoundException // The operation did not succeed because the resource requested is not found // in the service. @@ -3799,90 +4398,104 @@ func (c *CodeArtifact) TagResourceRequest(input *TagResourceInput) (req *request // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/TagResource -func (c *CodeArtifact) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { - req, out := c.TagResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PublishPackageVersion +func (c *CodeArtifact) PublishPackageVersion(input *PublishPackageVersionInput) (*PublishPackageVersionOutput, error) { + req, out := c.PublishPackageVersionRequest(input) return out, req.Send() } -// TagResourceWithContext is the same as TagResource with the addition of +// PublishPackageVersionWithContext is the same as PublishPackageVersion with the addition of // the ability to pass a context and additional request options. // -// See TagResource for details on how to use this API operation. +// See PublishPackageVersion for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { - req, out := c.TagResourceRequest(input) +func (c *CodeArtifact) PublishPackageVersionWithContext(ctx aws.Context, input *PublishPackageVersionInput, opts ...request.Option) (*PublishPackageVersionOutput, error) { + req, out := c.PublishPackageVersionRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUntagResource = "UntagResource" +const opPutDomainPermissionsPolicy = "PutDomainPermissionsPolicy" -// UntagResourceRequest generates a "aws/request.Request" representing the -// client's request for the UntagResource operation. The "output" return +// PutDomainPermissionsPolicyRequest generates a "aws/request.Request" representing the +// client's request for the PutDomainPermissionsPolicy operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UntagResource for more information on using the UntagResource +// See PutDomainPermissionsPolicy for more information on using the PutDomainPermissionsPolicy // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UntagResourceRequest method. -// req, resp := client.UntagResourceRequest(params) +// // Example sending a request using the PutDomainPermissionsPolicyRequest method. +// req, resp := client.PutDomainPermissionsPolicyRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UntagResource -func (c *CodeArtifact) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutDomainPermissionsPolicy +func (c *CodeArtifact) PutDomainPermissionsPolicyRequest(input *PutDomainPermissionsPolicyInput) (req *request.Request, output *PutDomainPermissionsPolicyOutput) { op := &request.Operation{ - Name: opUntagResource, - HTTPMethod: "POST", - HTTPPath: "/v1/untag", + Name: opPutDomainPermissionsPolicy, + HTTPMethod: "PUT", + HTTPPath: "/v1/domain/permissions/policy", } if input == nil { - input = &UntagResourceInput{} + input = &PutDomainPermissionsPolicyInput{} } - output = &UntagResourceOutput{} + output = &PutDomainPermissionsPolicyOutput{} req = c.newRequest(op, input, output) - req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) return } -// UntagResource API operation for CodeArtifact. +// PutDomainPermissionsPolicy API operation for CodeArtifact. // -// Removes tags from a resource in CodeArtifact. +// Sets a resource policy on a domain that specifies permissions to access it. +// +// When you call PutDomainPermissionsPolicy, the resource policy on the domain +// is ignored when evaluting permissions. This ensures that the owner of a domain +// cannot lock themselves out of the domain, which would prevent them from being +// able to update the resource policy. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation UntagResource for usage and error information. +// API operation PutDomainPermissionsPolicy for usage and error information. // // Returned Error Types: // // - AccessDeniedException // The operation did not succeed because of an unauthorized access attempt. // +// - ConflictException +// The operation did not succeed because prerequisites are not met. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// // - ResourceNotFoundException // The operation did not succeed because the resource requested is not found // in the service. // +// - ServiceQuotaExceededException +// The operation did not succeed because it would have exceeded a service limit +// for your account. +// // - ThrottlingException // The operation did not succeed because too many requests are sent to the service. // @@ -3890,91 +4503,101 @@ func (c *CodeArtifact) UntagResourceRequest(input *UntagResourceInput) (req *req // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UntagResource -func (c *CodeArtifact) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { - req, out := c.UntagResourceRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutDomainPermissionsPolicy +func (c *CodeArtifact) PutDomainPermissionsPolicy(input *PutDomainPermissionsPolicyInput) (*PutDomainPermissionsPolicyOutput, error) { + req, out := c.PutDomainPermissionsPolicyRequest(input) return out, req.Send() } -// UntagResourceWithContext is the same as UntagResource with the addition of +// PutDomainPermissionsPolicyWithContext is the same as PutDomainPermissionsPolicy with the addition of // the ability to pass a context and additional request options. // -// See UntagResource for details on how to use this API operation. +// See PutDomainPermissionsPolicy for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { - req, out := c.UntagResourceRequest(input) +func (c *CodeArtifact) PutDomainPermissionsPolicyWithContext(ctx aws.Context, input *PutDomainPermissionsPolicyInput, opts ...request.Option) (*PutDomainPermissionsPolicyOutput, error) { + req, out := c.PutDomainPermissionsPolicyRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdatePackageVersionsStatus = "UpdatePackageVersionsStatus" +const opPutPackageOriginConfiguration = "PutPackageOriginConfiguration" -// UpdatePackageVersionsStatusRequest generates a "aws/request.Request" representing the -// client's request for the UpdatePackageVersionsStatus operation. The "output" return +// PutPackageOriginConfigurationRequest generates a "aws/request.Request" representing the +// client's request for the PutPackageOriginConfiguration operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdatePackageVersionsStatus for more information on using the UpdatePackageVersionsStatus +// See PutPackageOriginConfiguration for more information on using the PutPackageOriginConfiguration // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UpdatePackageVersionsStatusRequest method. -// req, resp := client.UpdatePackageVersionsStatusRequest(params) +// // Example sending a request using the PutPackageOriginConfigurationRequest method. +// req, resp := client.PutPackageOriginConfigurationRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdatePackageVersionsStatus -func (c *CodeArtifact) UpdatePackageVersionsStatusRequest(input *UpdatePackageVersionsStatusInput) (req *request.Request, output *UpdatePackageVersionsStatusOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutPackageOriginConfiguration +func (c *CodeArtifact) PutPackageOriginConfigurationRequest(input *PutPackageOriginConfigurationInput) (req *request.Request, output *PutPackageOriginConfigurationOutput) { op := &request.Operation{ - Name: opUpdatePackageVersionsStatus, + Name: opPutPackageOriginConfiguration, HTTPMethod: "POST", - HTTPPath: "/v1/package/versions/update_status", + HTTPPath: "/v1/package", } if input == nil { - input = &UpdatePackageVersionsStatusInput{} + input = &PutPackageOriginConfigurationInput{} } - output = &UpdatePackageVersionsStatusOutput{} + output = &PutPackageOriginConfigurationOutput{} req = c.newRequest(op, input, output) return } -// UpdatePackageVersionsStatus API operation for CodeArtifact. +// PutPackageOriginConfiguration API operation for CodeArtifact. // -// Updates the status of one or more versions of a package. Using UpdatePackageVersionsStatus, -// you can update the status of package versions to Archived, Published, or -// Unlisted. To set the status of a package version to Disposed, use DisposePackageVersions -// (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_DisposePackageVersions.html). +// Sets the package origin configuration for a package. +// +// The package origin configuration determines how new versions of a package +// can be added to a repository. You can allow or block direct publishing of +// new package versions, or ingestion and retaining of new package versions +// from an external connection or upstream source. For more information about +// package origin controls and configuration, see Editing package origin controls +// (https://docs.aws.amazon.com/codeartifact/latest/ug/package-origin-controls.html) +// in the CodeArtifact User Guide. +// +// PutPackageOriginConfiguration can be called on a package that doesn't yet +// exist in the repository. When called on a package that does not exist, a +// package is created in the repository with no versions and the requested restrictions +// are set on the package. This can be used to preemptively block ingesting +// or retaining any versions from external connections or upstream repositories, +// or to block publishing any versions of the package into the repository before +// connecting any package managers or publishers to the repository. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation UpdatePackageVersionsStatus for usage and error information. +// API operation PutPackageOriginConfiguration for usage and error information. // // Returned Error Types: // // - AccessDeniedException // The operation did not succeed because of an unauthorized access attempt. // -// - ConflictException -// The operation did not succeed because prerequisites are not met. -// // - InternalServerException // The operation did not succeed because of an error that occurred inside CodeArtifact. // @@ -3989,79 +4612,85 @@ func (c *CodeArtifact) UpdatePackageVersionsStatusRequest(input *UpdatePackageVe // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdatePackageVersionsStatus -func (c *CodeArtifact) UpdatePackageVersionsStatus(input *UpdatePackageVersionsStatusInput) (*UpdatePackageVersionsStatusOutput, error) { - req, out := c.UpdatePackageVersionsStatusRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutPackageOriginConfiguration +func (c *CodeArtifact) PutPackageOriginConfiguration(input *PutPackageOriginConfigurationInput) (*PutPackageOriginConfigurationOutput, error) { + req, out := c.PutPackageOriginConfigurationRequest(input) return out, req.Send() } -// UpdatePackageVersionsStatusWithContext is the same as UpdatePackageVersionsStatus with the addition of +// PutPackageOriginConfigurationWithContext is the same as PutPackageOriginConfiguration with the addition of // the ability to pass a context and additional request options. // -// See UpdatePackageVersionsStatus for details on how to use this API operation. +// See PutPackageOriginConfiguration for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) UpdatePackageVersionsStatusWithContext(ctx aws.Context, input *UpdatePackageVersionsStatusInput, opts ...request.Option) (*UpdatePackageVersionsStatusOutput, error) { - req, out := c.UpdatePackageVersionsStatusRequest(input) +func (c *CodeArtifact) PutPackageOriginConfigurationWithContext(ctx aws.Context, input *PutPackageOriginConfigurationInput, opts ...request.Option) (*PutPackageOriginConfigurationOutput, error) { + req, out := c.PutPackageOriginConfigurationRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -const opUpdateRepository = "UpdateRepository" +const opPutRepositoryPermissionsPolicy = "PutRepositoryPermissionsPolicy" -// UpdateRepositoryRequest generates a "aws/request.Request" representing the -// client's request for the UpdateRepository operation. The "output" return +// PutRepositoryPermissionsPolicyRequest generates a "aws/request.Request" representing the +// client's request for the PutRepositoryPermissionsPolicy operation. The "output" return // value will be populated with the request's response once the request completes // successfully. // // Use "Send" method on the returned Request to send the API call to the service. // the "output" return value is not valid until after Send returns without error. // -// See UpdateRepository for more information on using the UpdateRepository +// See PutRepositoryPermissionsPolicy for more information on using the PutRepositoryPermissionsPolicy // API call, and error handling. // // This method is useful when you want to inject custom logic or configuration // into the SDK's request lifecycle. Such as custom headers, or retry logic. // -// // Example sending a request using the UpdateRepositoryRequest method. -// req, resp := client.UpdateRepositoryRequest(params) +// // Example sending a request using the PutRepositoryPermissionsPolicyRequest method. +// req, resp := client.PutRepositoryPermissionsPolicyRequest(params) // // err := req.Send() // if err == nil { // resp is now filled // fmt.Println(resp) // } // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdateRepository -func (c *CodeArtifact) UpdateRepositoryRequest(input *UpdateRepositoryInput) (req *request.Request, output *UpdateRepositoryOutput) { +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutRepositoryPermissionsPolicy +func (c *CodeArtifact) PutRepositoryPermissionsPolicyRequest(input *PutRepositoryPermissionsPolicyInput) (req *request.Request, output *PutRepositoryPermissionsPolicyOutput) { op := &request.Operation{ - Name: opUpdateRepository, + Name: opPutRepositoryPermissionsPolicy, HTTPMethod: "PUT", - HTTPPath: "/v1/repository", + HTTPPath: "/v1/repository/permissions/policy", } if input == nil { - input = &UpdateRepositoryInput{} + input = &PutRepositoryPermissionsPolicyInput{} } - output = &UpdateRepositoryOutput{} + output = &PutRepositoryPermissionsPolicyOutput{} req = c.newRequest(op, input, output) return } -// UpdateRepository API operation for CodeArtifact. +// PutRepositoryPermissionsPolicy API operation for CodeArtifact. // -// Update the properties of a repository. +// Sets the resource policy on a repository that specifies permissions to access +// it. +// +// When you call PutRepositoryPermissionsPolicy, the resource policy on the +// repository is ignored when evaluting permissions. This ensures that the owner +// of a repository cannot lock themselves out of the repository, which would +// prevent them from being able to update the resource policy. // // Returns awserr.Error for service API and SDK errors. Use runtime type assertions // with awserr.Error's Code and Message methods to get detailed information about // the error. // // See the AWS API reference guide for CodeArtifact's -// API operation UpdateRepository for usage and error information. +// API operation PutRepositoryPermissionsPolicy for usage and error information. // // Returned Error Types: // @@ -4089,148 +4718,2197 @@ func (c *CodeArtifact) UpdateRepositoryRequest(input *UpdateRepositoryInput) (re // The operation did not succeed because a parameter in the request was sent // with an invalid value. // -// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdateRepository -func (c *CodeArtifact) UpdateRepository(input *UpdateRepositoryInput) (*UpdateRepositoryOutput, error) { - req, out := c.UpdateRepositoryRequest(input) +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/PutRepositoryPermissionsPolicy +func (c *CodeArtifact) PutRepositoryPermissionsPolicy(input *PutRepositoryPermissionsPolicyInput) (*PutRepositoryPermissionsPolicyOutput, error) { + req, out := c.PutRepositoryPermissionsPolicyRequest(input) return out, req.Send() } -// UpdateRepositoryWithContext is the same as UpdateRepository with the addition of +// PutRepositoryPermissionsPolicyWithContext is the same as PutRepositoryPermissionsPolicy with the addition of // the ability to pass a context and additional request options. // -// See UpdateRepository for details on how to use this API operation. +// See PutRepositoryPermissionsPolicy for details on how to use this API operation. // // The context must be non-nil and will be used for request cancellation. If // the context is nil a panic will occur. In the future the SDK may create // sub-contexts for http.Requests. See https://golang.org/pkg/context/ // for more information on using Contexts. -func (c *CodeArtifact) UpdateRepositoryWithContext(ctx aws.Context, input *UpdateRepositoryInput, opts ...request.Option) (*UpdateRepositoryOutput, error) { - req, out := c.UpdateRepositoryRequest(input) +func (c *CodeArtifact) PutRepositoryPermissionsPolicyWithContext(ctx aws.Context, input *PutRepositoryPermissionsPolicyInput, opts ...request.Option) (*PutRepositoryPermissionsPolicyOutput, error) { + req, out := c.PutRepositoryPermissionsPolicyRequest(input) req.SetContext(ctx) req.ApplyOptions(opts...) return out, req.Send() } -// The operation did not succeed because of an unauthorized access attempt. -type AccessDeniedException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - - Message_ *string `locationName:"message" type:"string"` -} +const opTagResource = "TagResource" -// String returns the string representation. +// TagResourceRequest generates a "aws/request.Request" representing the +// client's request for the TagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s AccessDeniedException) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation. +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s AccessDeniedException) GoString() string { - return s.String() -} - -func newErrorAccessDeniedException(v protocol.ResponseMetadata) error { - return &AccessDeniedException{ - RespMetadata: v, +// See TagResource for more information on using the TagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the TagResourceRequest method. +// req, resp := client.TagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/TagResource +func (c *CodeArtifact) TagResourceRequest(input *TagResourceInput) (req *request.Request, output *TagResourceOutput) { + op := &request.Operation{ + Name: opTagResource, + HTTPMethod: "POST", + HTTPPath: "/v1/tag", } -} - -// Code returns the exception type name. -func (s *AccessDeniedException) Code() string { - return "AccessDeniedException" -} -// Message returns the exception's message. -func (s *AccessDeniedException) Message() string { - if s.Message_ != nil { - return *s.Message_ + if input == nil { + input = &TagResourceInput{} } - return "" -} - -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *AccessDeniedException) OrigErr() error { - return nil -} -func (s *AccessDeniedException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) + output = &TagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return } -// Status code returns the HTTP status code for the request's response error. -func (s *AccessDeniedException) StatusCode() int { - return s.RespMetadata.StatusCode +// TagResource API operation for CodeArtifact. +// +// Adds or updates tags for a resource in CodeArtifact. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation TagResource for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// - ServiceQuotaExceededException +// The operation did not succeed because it would have exceeded a service limit +// for your account. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/TagResource +func (c *CodeArtifact) TagResource(input *TagResourceInput) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + return out, req.Send() } -// RequestID returns the service's response RequestID for request. -func (s *AccessDeniedException) RequestID() string { - return s.RespMetadata.RequestID +// TagResourceWithContext is the same as TagResource with the addition of +// the ability to pass a context and additional request options. +// +// See TagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) TagResourceWithContext(ctx aws.Context, input *TagResourceInput, opts ...request.Option) (*TagResourceOutput, error) { + req, out := c.TagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() } -// Contains details about a package version asset. -type AssetSummary struct { - _ struct{} `type:"structure"` - - // The hashes of the asset. - Hashes map[string]*string `locationName:"hashes" type:"map"` - - // The name of the asset. - // - // Name is a required field - Name *string `locationName:"name" min:"1" type:"string" required:"true"` - - // The size of the asset. - Size *int64 `locationName:"size" type:"long"` -} +const opUntagResource = "UntagResource" -// String returns the string representation. +// UntagResourceRequest generates a "aws/request.Request" representing the +// client's request for the UntagResource operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s AssetSummary) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation. +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s AssetSummary) GoString() string { +// See UntagResource for more information on using the UntagResource +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UntagResourceRequest method. +// req, resp := client.UntagResourceRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UntagResource +func (c *CodeArtifact) UntagResourceRequest(input *UntagResourceInput) (req *request.Request, output *UntagResourceOutput) { + op := &request.Operation{ + Name: opUntagResource, + HTTPMethod: "POST", + HTTPPath: "/v1/untag", + } + + if input == nil { + input = &UntagResourceInput{} + } + + output = &UntagResourceOutput{} + req = c.newRequest(op, input, output) + req.Handlers.Unmarshal.Swap(restjson.UnmarshalHandler.Name, protocol.UnmarshalDiscardBodyHandler) + return +} + +// UntagResource API operation for CodeArtifact. +// +// Removes tags from a resource in CodeArtifact. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation UntagResource for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UntagResource +func (c *CodeArtifact) UntagResource(input *UntagResourceInput) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + return out, req.Send() +} + +// UntagResourceWithContext is the same as UntagResource with the addition of +// the ability to pass a context and additional request options. +// +// See UntagResource for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) UntagResourceWithContext(ctx aws.Context, input *UntagResourceInput, opts ...request.Option) (*UntagResourceOutput, error) { + req, out := c.UntagResourceRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdatePackageGroup = "UpdatePackageGroup" + +// UpdatePackageGroupRequest generates a "aws/request.Request" representing the +// client's request for the UpdatePackageGroup operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdatePackageGroup for more information on using the UpdatePackageGroup +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdatePackageGroupRequest method. +// req, resp := client.UpdatePackageGroupRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdatePackageGroup +func (c *CodeArtifact) UpdatePackageGroupRequest(input *UpdatePackageGroupInput) (req *request.Request, output *UpdatePackageGroupOutput) { + op := &request.Operation{ + Name: opUpdatePackageGroup, + HTTPMethod: "PUT", + HTTPPath: "/v1/package-group", + } + + if input == nil { + input = &UpdatePackageGroupInput{} + } + + output = &UpdatePackageGroupOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdatePackageGroup API operation for CodeArtifact. +// +// Updates a package group. This API cannot be used to update a package group's +// origin configuration or pattern. To update a package group's origin configuration, +// use UpdatePackageGroupOriginConfiguration (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_UpdatePackageGroupOriginConfiguration.html). +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation UpdatePackageGroup for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// +// - ServiceQuotaExceededException +// The operation did not succeed because it would have exceeded a service limit +// for your account. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdatePackageGroup +func (c *CodeArtifact) UpdatePackageGroup(input *UpdatePackageGroupInput) (*UpdatePackageGroupOutput, error) { + req, out := c.UpdatePackageGroupRequest(input) + return out, req.Send() +} + +// UpdatePackageGroupWithContext is the same as UpdatePackageGroup with the addition of +// the ability to pass a context and additional request options. +// +// See UpdatePackageGroup for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) UpdatePackageGroupWithContext(ctx aws.Context, input *UpdatePackageGroupInput, opts ...request.Option) (*UpdatePackageGroupOutput, error) { + req, out := c.UpdatePackageGroupRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdatePackageGroupOriginConfiguration = "UpdatePackageGroupOriginConfiguration" + +// UpdatePackageGroupOriginConfigurationRequest generates a "aws/request.Request" representing the +// client's request for the UpdatePackageGroupOriginConfiguration operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdatePackageGroupOriginConfiguration for more information on using the UpdatePackageGroupOriginConfiguration +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdatePackageGroupOriginConfigurationRequest method. +// req, resp := client.UpdatePackageGroupOriginConfigurationRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdatePackageGroupOriginConfiguration +func (c *CodeArtifact) UpdatePackageGroupOriginConfigurationRequest(input *UpdatePackageGroupOriginConfigurationInput) (req *request.Request, output *UpdatePackageGroupOriginConfigurationOutput) { + op := &request.Operation{ + Name: opUpdatePackageGroupOriginConfiguration, + HTTPMethod: "PUT", + HTTPPath: "/v1/package-group-origin-configuration", + } + + if input == nil { + input = &UpdatePackageGroupOriginConfigurationInput{} + } + + output = &UpdatePackageGroupOriginConfigurationOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdatePackageGroupOriginConfiguration API operation for CodeArtifact. +// +// Updates the package origin configuration for a package group. +// +// The package origin configuration determines how new versions of a package +// can be added to a repository. You can allow or block direct publishing of +// new package versions, or ingestion and retaining of new package versions +// from an external connection or upstream source. For more information about +// package group origin controls and configuration, see Package group origin +// controls (https://docs.aws.amazon.com/codeartifact/latest/ug/package-group-origin-controls.html) +// in the CodeArtifact User Guide. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation UpdatePackageGroupOriginConfiguration for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// +// - ServiceQuotaExceededException +// The operation did not succeed because it would have exceeded a service limit +// for your account. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdatePackageGroupOriginConfiguration +func (c *CodeArtifact) UpdatePackageGroupOriginConfiguration(input *UpdatePackageGroupOriginConfigurationInput) (*UpdatePackageGroupOriginConfigurationOutput, error) { + req, out := c.UpdatePackageGroupOriginConfigurationRequest(input) + return out, req.Send() +} + +// UpdatePackageGroupOriginConfigurationWithContext is the same as UpdatePackageGroupOriginConfiguration with the addition of +// the ability to pass a context and additional request options. +// +// See UpdatePackageGroupOriginConfiguration for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) UpdatePackageGroupOriginConfigurationWithContext(ctx aws.Context, input *UpdatePackageGroupOriginConfigurationInput, opts ...request.Option) (*UpdatePackageGroupOriginConfigurationOutput, error) { + req, out := c.UpdatePackageGroupOriginConfigurationRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdatePackageVersionsStatus = "UpdatePackageVersionsStatus" + +// UpdatePackageVersionsStatusRequest generates a "aws/request.Request" representing the +// client's request for the UpdatePackageVersionsStatus operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdatePackageVersionsStatus for more information on using the UpdatePackageVersionsStatus +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdatePackageVersionsStatusRequest method. +// req, resp := client.UpdatePackageVersionsStatusRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdatePackageVersionsStatus +func (c *CodeArtifact) UpdatePackageVersionsStatusRequest(input *UpdatePackageVersionsStatusInput) (req *request.Request, output *UpdatePackageVersionsStatusOutput) { + op := &request.Operation{ + Name: opUpdatePackageVersionsStatus, + HTTPMethod: "POST", + HTTPPath: "/v1/package/versions/update_status", + } + + if input == nil { + input = &UpdatePackageVersionsStatusInput{} + } + + output = &UpdatePackageVersionsStatusOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdatePackageVersionsStatus API operation for CodeArtifact. +// +// Updates the status of one or more versions of a package. Using UpdatePackageVersionsStatus, +// you can update the status of package versions to Archived, Published, or +// Unlisted. To set the status of a package version to Disposed, use DisposePackageVersions +// (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_DisposePackageVersions.html). +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation UpdatePackageVersionsStatus for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - ConflictException +// The operation did not succeed because prerequisites are not met. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdatePackageVersionsStatus +func (c *CodeArtifact) UpdatePackageVersionsStatus(input *UpdatePackageVersionsStatusInput) (*UpdatePackageVersionsStatusOutput, error) { + req, out := c.UpdatePackageVersionsStatusRequest(input) + return out, req.Send() +} + +// UpdatePackageVersionsStatusWithContext is the same as UpdatePackageVersionsStatus with the addition of +// the ability to pass a context and additional request options. +// +// See UpdatePackageVersionsStatus for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) UpdatePackageVersionsStatusWithContext(ctx aws.Context, input *UpdatePackageVersionsStatusInput, opts ...request.Option) (*UpdatePackageVersionsStatusOutput, error) { + req, out := c.UpdatePackageVersionsStatusRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +const opUpdateRepository = "UpdateRepository" + +// UpdateRepositoryRequest generates a "aws/request.Request" representing the +// client's request for the UpdateRepository operation. The "output" return +// value will be populated with the request's response once the request completes +// successfully. +// +// Use "Send" method on the returned Request to send the API call to the service. +// the "output" return value is not valid until after Send returns without error. +// +// See UpdateRepository for more information on using the UpdateRepository +// API call, and error handling. +// +// This method is useful when you want to inject custom logic or configuration +// into the SDK's request lifecycle. Such as custom headers, or retry logic. +// +// // Example sending a request using the UpdateRepositoryRequest method. +// req, resp := client.UpdateRepositoryRequest(params) +// +// err := req.Send() +// if err == nil { // resp is now filled +// fmt.Println(resp) +// } +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdateRepository +func (c *CodeArtifact) UpdateRepositoryRequest(input *UpdateRepositoryInput) (req *request.Request, output *UpdateRepositoryOutput) { + op := &request.Operation{ + Name: opUpdateRepository, + HTTPMethod: "PUT", + HTTPPath: "/v1/repository", + } + + if input == nil { + input = &UpdateRepositoryInput{} + } + + output = &UpdateRepositoryOutput{} + req = c.newRequest(op, input, output) + return +} + +// UpdateRepository API operation for CodeArtifact. +// +// Update the properties of a repository. +// +// Returns awserr.Error for service API and SDK errors. Use runtime type assertions +// with awserr.Error's Code and Message methods to get detailed information about +// the error. +// +// See the AWS API reference guide for CodeArtifact's +// API operation UpdateRepository for usage and error information. +// +// Returned Error Types: +// +// - AccessDeniedException +// The operation did not succeed because of an unauthorized access attempt. +// +// - ConflictException +// The operation did not succeed because prerequisites are not met. +// +// - InternalServerException +// The operation did not succeed because of an error that occurred inside CodeArtifact. +// +// - ResourceNotFoundException +// The operation did not succeed because the resource requested is not found +// in the service. +// +// - ServiceQuotaExceededException +// The operation did not succeed because it would have exceeded a service limit +// for your account. +// +// - ThrottlingException +// The operation did not succeed because too many requests are sent to the service. +// +// - ValidationException +// The operation did not succeed because a parameter in the request was sent +// with an invalid value. +// +// See also, https://docs.aws.amazon.com/goto/WebAPI/codeartifact-2018-09-22/UpdateRepository +func (c *CodeArtifact) UpdateRepository(input *UpdateRepositoryInput) (*UpdateRepositoryOutput, error) { + req, out := c.UpdateRepositoryRequest(input) + return out, req.Send() +} + +// UpdateRepositoryWithContext is the same as UpdateRepository with the addition of +// the ability to pass a context and additional request options. +// +// See UpdateRepository for details on how to use this API operation. +// +// The context must be non-nil and will be used for request cancellation. If +// the context is nil a panic will occur. In the future the SDK may create +// sub-contexts for http.Requests. See https://golang.org/pkg/context/ +// for more information on using Contexts. +func (c *CodeArtifact) UpdateRepositoryWithContext(ctx aws.Context, input *UpdateRepositoryInput, opts ...request.Option) (*UpdateRepositoryOutput, error) { + req, out := c.UpdateRepositoryRequest(input) + req.SetContext(ctx) + req.ApplyOptions(opts...) + return out, req.Send() +} + +// The operation did not succeed because of an unauthorized access attempt. +type AccessDeniedException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + Message_ *string `locationName:"message" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AccessDeniedException) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AccessDeniedException) GoString() string { + return s.String() +} + +func newErrorAccessDeniedException(v protocol.ResponseMetadata) error { + return &AccessDeniedException{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *AccessDeniedException) Code() string { + return "AccessDeniedException" +} + +// Message returns the exception's message. +func (s *AccessDeniedException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *AccessDeniedException) OrigErr() error { + return nil +} + +func (s *AccessDeniedException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *AccessDeniedException) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *AccessDeniedException) RequestID() string { + return s.RespMetadata.RequestID +} + +// Contains details about a package version asset. +type AssetSummary struct { + _ struct{} `type:"structure"` + + // The hashes of the asset. + Hashes map[string]*string `locationName:"hashes" type:"map"` + + // The name of the asset. + // + // Name is a required field + Name *string `locationName:"name" min:"1" type:"string" required:"true"` + + // The size of the asset. + Size *int64 `locationName:"size" type:"long"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssetSummary) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssetSummary) GoString() string { + return s.String() +} + +// SetHashes sets the Hashes field's value. +func (s *AssetSummary) SetHashes(v map[string]*string) *AssetSummary { + s.Hashes = v + return s +} + +// SetName sets the Name field's value. +func (s *AssetSummary) SetName(v string) *AssetSummary { + s.Name = &v + return s +} + +// SetSize sets the Size field's value. +func (s *AssetSummary) SetSize(v int64) *AssetSummary { + s.Size = &v + return s +} + +type AssociateExternalConnectionInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The name of the domain that contains the repository. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The name of the external connection to add to the repository. The following + // values are supported: + // + // * public:npmjs - for the npm public repository. + // + // * public:nuget-org - for the NuGet Gallery. + // + // * public:pypi - for the Python Package Index. + // + // * public:maven-central - for Maven Central. + // + // * public:maven-googleandroid - for the Google Android repository. + // + // * public:maven-gradleplugins - for the Gradle plugins repository. + // + // * public:maven-commonsware - for the CommonsWare Android repository. + // + // * public:maven-clojars - for the Clojars repository. + // + // ExternalConnection is a required field + ExternalConnection *string `location:"querystring" locationName:"external-connection" min:"2" type:"string" required:"true"` + + // The name of the repository to which the external connection is added. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociateExternalConnectionInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociateExternalConnectionInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *AssociateExternalConnectionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "AssociateExternalConnectionInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.ExternalConnection == nil { + invalidParams.Add(request.NewErrParamRequired("ExternalConnection")) + } + if s.ExternalConnection != nil && len(*s.ExternalConnection) < 2 { + invalidParams.Add(request.NewErrParamMinLen("ExternalConnection", 2)) + } + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDomain sets the Domain field's value. +func (s *AssociateExternalConnectionInput) SetDomain(v string) *AssociateExternalConnectionInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *AssociateExternalConnectionInput) SetDomainOwner(v string) *AssociateExternalConnectionInput { + s.DomainOwner = &v + return s +} + +// SetExternalConnection sets the ExternalConnection field's value. +func (s *AssociateExternalConnectionInput) SetExternalConnection(v string) *AssociateExternalConnectionInput { + s.ExternalConnection = &v + return s +} + +// SetRepository sets the Repository field's value. +func (s *AssociateExternalConnectionInput) SetRepository(v string) *AssociateExternalConnectionInput { + s.Repository = &v + return s +} + +type AssociateExternalConnectionOutput struct { + _ struct{} `type:"structure"` + + // Information about the connected repository after processing the request. + Repository *RepositoryDescription `locationName:"repository" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociateExternalConnectionOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociateExternalConnectionOutput) GoString() string { + return s.String() +} + +// SetRepository sets the Repository field's value. +func (s *AssociateExternalConnectionOutput) SetRepository(v *RepositoryDescription) *AssociateExternalConnectionOutput { + s.Repository = v + return s +} + +// A package associated with a package group. +type AssociatedPackage struct { + _ struct{} `type:"structure"` + + // Describes the strength of the association between the package and package + // group. A strong match can be thought of as an exact match, and a weak match + // can be thought of as a variation match, for example, the package name matches + // a variation of the package group pattern. For more information about package + // group pattern matching, including strong and weak matches, see Package group + // definition syntax and matching behavior (https://docs.aws.amazon.com/codeartifact/latest/ug/package-group-definition-syntax-matching-behavior.html) + // in the CodeArtifact User Guide. + AssociationType *string `locationName:"associationType" type:"string" enum:"PackageGroupAssociationType"` + + // A format that specifies the type of the associated package. + Format *string `locationName:"format" type:"string" enum:"PackageFormat"` + + // The namespace of the associated package. The package component that specifies + // its namespace depends on its type. For example: + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `locationName:"namespace" min:"1" type:"string"` + + // The name of the associated package. + Package *string `locationName:"package" min:"1" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociatedPackage) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s AssociatedPackage) GoString() string { + return s.String() +} + +// SetAssociationType sets the AssociationType field's value. +func (s *AssociatedPackage) SetAssociationType(v string) *AssociatedPackage { + s.AssociationType = &v + return s +} + +// SetFormat sets the Format field's value. +func (s *AssociatedPackage) SetFormat(v string) *AssociatedPackage { + s.Format = &v + return s +} + +// SetNamespace sets the Namespace field's value. +func (s *AssociatedPackage) SetNamespace(v string) *AssociatedPackage { + s.Namespace = &v + return s +} + +// SetPackage sets the Package field's value. +func (s *AssociatedPackage) SetPackage(v string) *AssociatedPackage { + s.Package = &v + return s +} + +// The operation did not succeed because prerequisites are not met. +type ConflictException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` + + Message_ *string `locationName:"message" type:"string"` + + // The ID of the resource. + ResourceId *string `locationName:"resourceId" type:"string"` + + // The type of Amazon Web Services resource. + ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConflictException) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ConflictException) GoString() string { + return s.String() +} + +func newErrorConflictException(v protocol.ResponseMetadata) error { + return &ConflictException{ + RespMetadata: v, + } +} + +// Code returns the exception type name. +func (s *ConflictException) Code() string { + return "ConflictException" +} + +// Message returns the exception's message. +func (s *ConflictException) Message() string { + if s.Message_ != nil { + return *s.Message_ + } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *ConflictException) OrigErr() error { + return nil +} + +func (s *ConflictException) Error() string { + return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) +} + +// Status code returns the HTTP status code for the request's response error. +func (s *ConflictException) StatusCode() int { + return s.RespMetadata.StatusCode +} + +// RequestID returns the service's response RequestID for request. +func (s *ConflictException) RequestID() string { + return s.RespMetadata.RequestID +} + +type CopyPackageVersionsInput struct { + _ struct{} `type:"structure"` + + // Set to true to overwrite a package version that already exists in the destination + // repository. If set to false and the package version already exists in the + // destination repository, the package version is returned in the failedVersions + // field of the response with an ALREADY_EXISTS error code. + AllowOverwrite *bool `locationName:"allowOverwrite" type:"boolean"` + + // The name of the repository into which package versions are copied. + // + // DestinationRepository is a required field + DestinationRepository *string `location:"querystring" locationName:"destination-repository" min:"2" type:"string" required:"true"` + + // The name of the domain that contains the source and destination repositories. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The format of the package versions to be copied. + // + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` + + // Set to true to copy packages from repositories that are upstream from the + // source repository to the destination repository. The default setting is false. + // For more information, see Working with upstream repositories (https://docs.aws.amazon.com/codeartifact/latest/ug/repos-upstream.html). + IncludeFromUpstream *bool `locationName:"includeFromUpstream" type:"boolean"` + + // The namespace of the package versions to be copied. The package component + // that specifies its namespace depends on its type. For example: + // + // The namespace is required when copying package versions of the following + // formats: + // + // * Maven + // + // * Swift + // + // * generic + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` + + // The name of the package that contains the versions to be copied. + // + // Package is a required field + Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + + // The name of the repository that contains the package versions to be copied. + // + // SourceRepository is a required field + SourceRepository *string `location:"querystring" locationName:"source-repository" min:"2" type:"string" required:"true"` + + // A list of key-value pairs. The keys are package versions and the values are + // package version revisions. A CopyPackageVersion operation succeeds if the + // specified versions in the source repository match the specified package version + // revision. + // + // You must specify versions or versionRevisions. You cannot specify both. + VersionRevisions map[string]*string `locationName:"versionRevisions" type:"map"` + + // The versions of the package to be copied. + // + // You must specify versions or versionRevisions. You cannot specify both. + Versions []*string `locationName:"versions" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CopyPackageVersionsInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CopyPackageVersionsInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CopyPackageVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CopyPackageVersionsInput"} + if s.DestinationRepository == nil { + invalidParams.Add(request.NewErrParamRequired("DestinationRepository")) + } + if s.DestinationRepository != nil && len(*s.DestinationRepository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("DestinationRepository", 2)) + } + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) + } + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) + } + if s.Package == nil { + invalidParams.Add(request.NewErrParamRequired("Package")) + } + if s.Package != nil && len(*s.Package) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + } + if s.SourceRepository == nil { + invalidParams.Add(request.NewErrParamRequired("SourceRepository")) + } + if s.SourceRepository != nil && len(*s.SourceRepository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("SourceRepository", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAllowOverwrite sets the AllowOverwrite field's value. +func (s *CopyPackageVersionsInput) SetAllowOverwrite(v bool) *CopyPackageVersionsInput { + s.AllowOverwrite = &v + return s +} + +// SetDestinationRepository sets the DestinationRepository field's value. +func (s *CopyPackageVersionsInput) SetDestinationRepository(v string) *CopyPackageVersionsInput { + s.DestinationRepository = &v + return s +} + +// SetDomain sets the Domain field's value. +func (s *CopyPackageVersionsInput) SetDomain(v string) *CopyPackageVersionsInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *CopyPackageVersionsInput) SetDomainOwner(v string) *CopyPackageVersionsInput { + s.DomainOwner = &v + return s +} + +// SetFormat sets the Format field's value. +func (s *CopyPackageVersionsInput) SetFormat(v string) *CopyPackageVersionsInput { + s.Format = &v + return s +} + +// SetIncludeFromUpstream sets the IncludeFromUpstream field's value. +func (s *CopyPackageVersionsInput) SetIncludeFromUpstream(v bool) *CopyPackageVersionsInput { + s.IncludeFromUpstream = &v + return s +} + +// SetNamespace sets the Namespace field's value. +func (s *CopyPackageVersionsInput) SetNamespace(v string) *CopyPackageVersionsInput { + s.Namespace = &v + return s +} + +// SetPackage sets the Package field's value. +func (s *CopyPackageVersionsInput) SetPackage(v string) *CopyPackageVersionsInput { + s.Package = &v + return s +} + +// SetSourceRepository sets the SourceRepository field's value. +func (s *CopyPackageVersionsInput) SetSourceRepository(v string) *CopyPackageVersionsInput { + s.SourceRepository = &v + return s +} + +// SetVersionRevisions sets the VersionRevisions field's value. +func (s *CopyPackageVersionsInput) SetVersionRevisions(v map[string]*string) *CopyPackageVersionsInput { + s.VersionRevisions = v + return s +} + +// SetVersions sets the Versions field's value. +func (s *CopyPackageVersionsInput) SetVersions(v []*string) *CopyPackageVersionsInput { + s.Versions = v + return s +} + +type CopyPackageVersionsOutput struct { + _ struct{} `type:"structure"` + + // A map of package versions that failed to copy and their error codes. The + // possible error codes are in the PackageVersionError data type. They are: + // + // * ALREADY_EXISTS + // + // * MISMATCHED_REVISION + // + // * MISMATCHED_STATUS + // + // * NOT_ALLOWED + // + // * NOT_FOUND + // + // * SKIPPED + FailedVersions map[string]*PackageVersionError `locationName:"failedVersions" type:"map"` + + // A list of the package versions that were successfully copied to your repository. + SuccessfulVersions map[string]*SuccessfulPackageVersionInfo `locationName:"successfulVersions" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CopyPackageVersionsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CopyPackageVersionsOutput) GoString() string { + return s.String() +} + +// SetFailedVersions sets the FailedVersions field's value. +func (s *CopyPackageVersionsOutput) SetFailedVersions(v map[string]*PackageVersionError) *CopyPackageVersionsOutput { + s.FailedVersions = v + return s +} + +// SetSuccessfulVersions sets the SuccessfulVersions field's value. +func (s *CopyPackageVersionsOutput) SetSuccessfulVersions(v map[string]*SuccessfulPackageVersionInfo) *CopyPackageVersionsOutput { + s.SuccessfulVersions = v + return s +} + +type CreateDomainInput struct { + _ struct{} `type:"structure"` + + // The name of the domain to create. All domain names in an Amazon Web Services + // Region that are in the same Amazon Web Services account must be unique. The + // domain name is used as the prefix in DNS hostnames. Do not use sensitive + // information in a domain name because it is publicly discoverable. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The encryption key for the domain. This is used to encrypt content stored + // in a domain. An encryption key can be a key ID, a key Amazon Resource Name + // (ARN), a key alias, or a key alias ARN. To specify an encryptionKey, your + // IAM role must have kms:DescribeKey and kms:CreateGrant permissions on the + // encryption key that is used. For more information, see DescribeKey (https://docs.aws.amazon.com/kms/latest/APIReference/API_DescribeKey.html#API_DescribeKey_RequestSyntax) + // in the Key Management Service API Reference and Key Management Service API + // Permissions Reference (https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html) + // in the Key Management Service Developer Guide. + // + // CodeArtifact supports only symmetric CMKs. Do not associate an asymmetric + // CMK with your domain. For more information, see Using symmetric and asymmetric + // keys (https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html) + // in the Key Management Service Developer Guide. + EncryptionKey *string `locationName:"encryptionKey" min:"1" type:"string"` + + // One or more tag key-value pairs for the domain. + Tags []*Tag `locationName:"tags" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateDomainInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateDomainInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateDomainInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateDomainInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.EncryptionKey != nil && len(*s.EncryptionKey) < 1 { + invalidParams.Add(request.NewErrParamMinLen("EncryptionKey", 1)) + } + if s.Tags != nil { + for i, v := range s.Tags { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDomain sets the Domain field's value. +func (s *CreateDomainInput) SetDomain(v string) *CreateDomainInput { + s.Domain = &v + return s +} + +// SetEncryptionKey sets the EncryptionKey field's value. +func (s *CreateDomainInput) SetEncryptionKey(v string) *CreateDomainInput { + s.EncryptionKey = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreateDomainInput) SetTags(v []*Tag) *CreateDomainInput { + s.Tags = v + return s +} + +type CreateDomainOutput struct { + _ struct{} `type:"structure"` + + // Contains information about the created domain after processing the request. + Domain *DomainDescription `locationName:"domain" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateDomainOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateDomainOutput) GoString() string { + return s.String() +} + +// SetDomain sets the Domain field's value. +func (s *CreateDomainOutput) SetDomain(v *DomainDescription) *CreateDomainOutput { + s.Domain = v + return s +} + +type CreatePackageGroupInput struct { + _ struct{} `type:"structure"` + + // The contact information for the created package group. + ContactInfo *string `locationName:"contactInfo" type:"string"` + + // A description of the package group. + Description *string `locationName:"description" type:"string"` + + // The name of the domain in which you want to create a package group. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The pattern of the package group to create. The pattern is also the identifier + // of the package group. + // + // PackageGroup is a required field + PackageGroup *string `locationName:"packageGroup" min:"2" type:"string" required:"true"` + + // One or more tag key-value pairs for the package group. + Tags []*Tag `locationName:"tags" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePackageGroupInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePackageGroupInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreatePackageGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreatePackageGroupInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.PackageGroup == nil { + invalidParams.Add(request.NewErrParamRequired("PackageGroup")) + } + if s.PackageGroup != nil && len(*s.PackageGroup) < 2 { + invalidParams.Add(request.NewErrParamMinLen("PackageGroup", 2)) + } + if s.Tags != nil { + for i, v := range s.Tags { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContactInfo sets the ContactInfo field's value. +func (s *CreatePackageGroupInput) SetContactInfo(v string) *CreatePackageGroupInput { + s.ContactInfo = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *CreatePackageGroupInput) SetDescription(v string) *CreatePackageGroupInput { + s.Description = &v + return s +} + +// SetDomain sets the Domain field's value. +func (s *CreatePackageGroupInput) SetDomain(v string) *CreatePackageGroupInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *CreatePackageGroupInput) SetDomainOwner(v string) *CreatePackageGroupInput { + s.DomainOwner = &v + return s +} + +// SetPackageGroup sets the PackageGroup field's value. +func (s *CreatePackageGroupInput) SetPackageGroup(v string) *CreatePackageGroupInput { + s.PackageGroup = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreatePackageGroupInput) SetTags(v []*Tag) *CreatePackageGroupInput { + s.Tags = v + return s +} + +type CreatePackageGroupOutput struct { + _ struct{} `type:"structure"` + + // Information about the created package group after processing the request. + PackageGroup *PackageGroupDescription `locationName:"packageGroup" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePackageGroupOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreatePackageGroupOutput) GoString() string { + return s.String() +} + +// SetPackageGroup sets the PackageGroup field's value. +func (s *CreatePackageGroupOutput) SetPackageGroup(v *PackageGroupDescription) *CreatePackageGroupOutput { + s.PackageGroup = v + return s +} + +type CreateRepositoryInput struct { + _ struct{} `type:"structure"` + + // A description of the created repository. + Description *string `locationName:"description" type:"string"` + + // The name of the domain that contains the created repository. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The name of the repository to create. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + + // One or more tag key-value pairs for the repository. + Tags []*Tag `locationName:"tags" type:"list"` + + // A list of upstream repositories to associate with the repository. The order + // of the upstream repositories in the list determines their priority order + // when CodeArtifact looks for a requested package version. For more information, + // see Working with upstream repositories (https://docs.aws.amazon.com/codeartifact/latest/ug/repos-upstream.html). + Upstreams []*UpstreamRepository `locationName:"upstreams" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateRepositoryInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateRepositoryInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *CreateRepositoryInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "CreateRepositoryInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + } + if s.Tags != nil { + for i, v := range s.Tags { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) + } + } + } + if s.Upstreams != nil { + for i, v := range s.Upstreams { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Upstreams", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDescription sets the Description field's value. +func (s *CreateRepositoryInput) SetDescription(v string) *CreateRepositoryInput { + s.Description = &v + return s +} + +// SetDomain sets the Domain field's value. +func (s *CreateRepositoryInput) SetDomain(v string) *CreateRepositoryInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *CreateRepositoryInput) SetDomainOwner(v string) *CreateRepositoryInput { + s.DomainOwner = &v + return s +} + +// SetRepository sets the Repository field's value. +func (s *CreateRepositoryInput) SetRepository(v string) *CreateRepositoryInput { + s.Repository = &v + return s +} + +// SetTags sets the Tags field's value. +func (s *CreateRepositoryInput) SetTags(v []*Tag) *CreateRepositoryInput { + s.Tags = v + return s +} + +// SetUpstreams sets the Upstreams field's value. +func (s *CreateRepositoryInput) SetUpstreams(v []*UpstreamRepository) *CreateRepositoryInput { + s.Upstreams = v + return s +} + +type CreateRepositoryOutput struct { + _ struct{} `type:"structure"` + + // Information about the created repository after processing the request. + Repository *RepositoryDescription `locationName:"repository" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateRepositoryOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s CreateRepositoryOutput) GoString() string { + return s.String() +} + +// SetRepository sets the Repository field's value. +func (s *CreateRepositoryOutput) SetRepository(v *RepositoryDescription) *CreateRepositoryOutput { + s.Repository = v + return s +} + +type DeleteDomainInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The name of the domain to delete. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDomainInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDomainInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteDomainInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteDomainInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDomain sets the Domain field's value. +func (s *DeleteDomainInput) SetDomain(v string) *DeleteDomainInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *DeleteDomainInput) SetDomainOwner(v string) *DeleteDomainInput { + s.DomainOwner = &v + return s +} + +type DeleteDomainOutput struct { + _ struct{} `type:"structure"` + + // Contains information about the deleted domain after processing the request. + Domain *DomainDescription `locationName:"domain" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDomainOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDomainOutput) GoString() string { + return s.String() +} + +// SetDomain sets the Domain field's value. +func (s *DeleteDomainOutput) SetDomain(v *DomainDescription) *DeleteDomainOutput { + s.Domain = v + return s +} + +type DeleteDomainPermissionsPolicyInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The name of the domain associated with the resource policy to be deleted. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The current revision of the resource policy to be deleted. This revision + // is used for optimistic locking, which prevents others from overwriting your + // changes to the domain's resource policy. + PolicyRevision *string `location:"querystring" locationName:"policy-revision" min:"1" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDomainPermissionsPolicyInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDomainPermissionsPolicyInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteDomainPermissionsPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteDomainPermissionsPolicyInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.PolicyRevision != nil && len(*s.PolicyRevision) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PolicyRevision", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDomain sets the Domain field's value. +func (s *DeleteDomainPermissionsPolicyInput) SetDomain(v string) *DeleteDomainPermissionsPolicyInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *DeleteDomainPermissionsPolicyInput) SetDomainOwner(v string) *DeleteDomainPermissionsPolicyInput { + s.DomainOwner = &v + return s +} + +// SetPolicyRevision sets the PolicyRevision field's value. +func (s *DeleteDomainPermissionsPolicyInput) SetPolicyRevision(v string) *DeleteDomainPermissionsPolicyInput { + s.PolicyRevision = &v + return s +} + +type DeleteDomainPermissionsPolicyOutput struct { + _ struct{} `type:"structure"` + + // Information about the deleted resource policy after processing the request. + Policy *ResourcePolicy `locationName:"policy" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDomainPermissionsPolicyOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteDomainPermissionsPolicyOutput) GoString() string { return s.String() } -// SetHashes sets the Hashes field's value. -func (s *AssetSummary) SetHashes(v map[string]*string) *AssetSummary { - s.Hashes = v +// SetPolicy sets the Policy field's value. +func (s *DeleteDomainPermissionsPolicyOutput) SetPolicy(v *ResourcePolicy) *DeleteDomainPermissionsPolicyOutput { + s.Policy = v + return s +} + +type DeletePackageGroupInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The domain that contains the package group to be deleted. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The pattern of the package group to be deleted. + // + // PackageGroup is a required field + PackageGroup *string `location:"querystring" locationName:"package-group" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePackageGroupInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePackageGroupInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeletePackageGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeletePackageGroupInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.PackageGroup == nil { + invalidParams.Add(request.NewErrParamRequired("PackageGroup")) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDomain sets the Domain field's value. +func (s *DeletePackageGroupInput) SetDomain(v string) *DeletePackageGroupInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *DeletePackageGroupInput) SetDomainOwner(v string) *DeletePackageGroupInput { + s.DomainOwner = &v + return s +} + +// SetPackageGroup sets the PackageGroup field's value. +func (s *DeletePackageGroupInput) SetPackageGroup(v string) *DeletePackageGroupInput { + s.PackageGroup = &v + return s +} + +type DeletePackageGroupOutput struct { + _ struct{} `type:"structure"` + + // Information about the deleted package group after processing the request. + PackageGroup *PackageGroupDescription `locationName:"packageGroup" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePackageGroupOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePackageGroupOutput) GoString() string { + return s.String() +} + +// SetPackageGroup sets the PackageGroup field's value. +func (s *DeletePackageGroupOutput) SetPackageGroup(v *PackageGroupDescription) *DeletePackageGroupOutput { + s.PackageGroup = v + return s +} + +type DeletePackageInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The name of the domain that contains the package to delete. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The format of the requested package to delete. + // + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` + + // The namespace of the package to delete. The package component that specifies + // its namespace depends on its type. For example: + // + // The namespace is required when deleting packages of the following formats: + // + // * Maven + // + // * Swift + // + // * generic + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` + + // The name of the package to delete. + // + // Package is a required field + Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + + // The name of the repository that contains the package to delete. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePackageInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePackageInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeletePackageInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeletePackageInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) + } + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) + } + if s.Package == nil { + invalidParams.Add(request.NewErrParamRequired("Package")) + } + if s.Package != nil && len(*s.Package) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + } + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDomain sets the Domain field's value. +func (s *DeletePackageInput) SetDomain(v string) *DeletePackageInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *DeletePackageInput) SetDomainOwner(v string) *DeletePackageInput { + s.DomainOwner = &v + return s +} + +// SetFormat sets the Format field's value. +func (s *DeletePackageInput) SetFormat(v string) *DeletePackageInput { + s.Format = &v + return s +} + +// SetNamespace sets the Namespace field's value. +func (s *DeletePackageInput) SetNamespace(v string) *DeletePackageInput { + s.Namespace = &v + return s +} + +// SetPackage sets the Package field's value. +func (s *DeletePackageInput) SetPackage(v string) *DeletePackageInput { + s.Package = &v return s } -// SetName sets the Name field's value. -func (s *AssetSummary) SetName(v string) *AssetSummary { - s.Name = &v - return s +// SetRepository sets the Repository field's value. +func (s *DeletePackageInput) SetRepository(v string) *DeletePackageInput { + s.Repository = &v + return s +} + +type DeletePackageOutput struct { + _ struct{} `type:"structure"` + + // Details about a package, including its format, namespace, and name. + DeletedPackage *PackageSummary `locationName:"deletedPackage" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePackageOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeletePackageOutput) GoString() string { + return s.String() } -// SetSize sets the Size field's value. -func (s *AssetSummary) SetSize(v int64) *AssetSummary { - s.Size = &v +// SetDeletedPackage sets the DeletedPackage field's value. +func (s *DeletePackageOutput) SetDeletedPackage(v *PackageSummary) *DeletePackageOutput { + s.DeletedPackage = v return s } -type AssociateExternalConnectionInput struct { - _ struct{} `type:"structure" nopayload:"true"` +type DeletePackageVersionsInput struct { + _ struct{} `type:"structure"` - // The name of the domain that contains the repository. + // The name of the domain that contains the package to delete. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -4239,32 +6917,50 @@ type AssociateExternalConnectionInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The name of the external connection to add to the repository. The following - // values are supported: + // The expected status of the package version to delete. + ExpectedStatus *string `locationName:"expectedStatus" type:"string" enum:"PackageVersionStatus"` + + // The format of the package versions to delete. // - // * public:npmjs - for the npm public repository. + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` + + // The namespace of the package versions to be deleted. The package component + // that specifies its namespace depends on its type. For example: // - // * public:nuget-org - for the NuGet Gallery. + // The namespace is required when deleting package versions of the following + // formats: // - // * public:pypi - for the Python Package Index. + // * Maven // - // * public:maven-central - for Maven Central. + // * Swift // - // * public:maven-googleandroid - for the Google Android repository. + // * generic // - // * public:maven-gradleplugins - for the Gradle plugins repository. + // * The namespace of a Maven package version is its groupId. // - // * public:maven-commonsware - for the CommonsWare Android repository. + // * The namespace of an npm or Swift package version is its scope. // - // * public:maven-clojars - for the Clojars repository. + // * The namespace of a generic package is its namespace. // - // ExternalConnection is a required field - ExternalConnection *string `location:"querystring" locationName:"external-connection" min:"2" type:"string" required:"true"` + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - // The name of the repository to which the external connection is added. + // The name of the package with the versions to delete. + // + // Package is a required field + Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + + // The name of the repository that contains the package versions to delete. // // Repository is a required field Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + + // An array of strings that specify the versions of the package to delete. + // + // Versions is a required field + Versions []*string `locationName:"versions" type:"list" required:"true"` } // String returns the string representation. @@ -4272,7 +6968,7 @@ type AssociateExternalConnectionInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AssociateExternalConnectionInput) String() string { +func (s DeletePackageVersionsInput) String() string { return awsutil.Prettify(s) } @@ -4281,13 +6977,13 @@ func (s AssociateExternalConnectionInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AssociateExternalConnectionInput) GoString() string { +func (s DeletePackageVersionsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *AssociateExternalConnectionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "AssociateExternalConnectionInput"} +func (s *DeletePackageVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeletePackageVersionsInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -4297,11 +6993,17 @@ func (s *AssociateExternalConnectionInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.ExternalConnection == nil { - invalidParams.Add(request.NewErrParamRequired("ExternalConnection")) + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) } - if s.ExternalConnection != nil && len(*s.ExternalConnection) < 2 { - invalidParams.Add(request.NewErrParamMinLen("ExternalConnection", 2)) + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) + } + if s.Package == nil { + invalidParams.Add(request.NewErrParamRequired("Package")) + } + if s.Package != nil && len(*s.Package) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Package", 1)) } if s.Repository == nil { invalidParams.Add(request.NewErrParamRequired("Repository")) @@ -4309,6 +7011,9 @@ func (s *AssociateExternalConnectionInput) Validate() error { if s.Repository != nil && len(*s.Repository) < 2 { invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) } + if s.Versions == nil { + invalidParams.Add(request.NewErrParamRequired("Versions")) + } if invalidParams.Len() > 0 { return invalidParams @@ -4317,34 +7022,75 @@ func (s *AssociateExternalConnectionInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *AssociateExternalConnectionInput) SetDomain(v string) *AssociateExternalConnectionInput { +func (s *DeletePackageVersionsInput) SetDomain(v string) *DeletePackageVersionsInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *AssociateExternalConnectionInput) SetDomainOwner(v string) *AssociateExternalConnectionInput { +func (s *DeletePackageVersionsInput) SetDomainOwner(v string) *DeletePackageVersionsInput { s.DomainOwner = &v return s } -// SetExternalConnection sets the ExternalConnection field's value. -func (s *AssociateExternalConnectionInput) SetExternalConnection(v string) *AssociateExternalConnectionInput { - s.ExternalConnection = &v +// SetExpectedStatus sets the ExpectedStatus field's value. +func (s *DeletePackageVersionsInput) SetExpectedStatus(v string) *DeletePackageVersionsInput { + s.ExpectedStatus = &v + return s +} + +// SetFormat sets the Format field's value. +func (s *DeletePackageVersionsInput) SetFormat(v string) *DeletePackageVersionsInput { + s.Format = &v + return s +} + +// SetNamespace sets the Namespace field's value. +func (s *DeletePackageVersionsInput) SetNamespace(v string) *DeletePackageVersionsInput { + s.Namespace = &v + return s +} + +// SetPackage sets the Package field's value. +func (s *DeletePackageVersionsInput) SetPackage(v string) *DeletePackageVersionsInput { + s.Package = &v return s } // SetRepository sets the Repository field's value. -func (s *AssociateExternalConnectionInput) SetRepository(v string) *AssociateExternalConnectionInput { +func (s *DeletePackageVersionsInput) SetRepository(v string) *DeletePackageVersionsInput { s.Repository = &v return s } -type AssociateExternalConnectionOutput struct { +// SetVersions sets the Versions field's value. +func (s *DeletePackageVersionsInput) SetVersions(v []*string) *DeletePackageVersionsInput { + s.Versions = v + return s +} + +type DeletePackageVersionsOutput struct { _ struct{} `type:"structure"` - // Information about the connected repository after processing the request. - Repository *RepositoryDescription `locationName:"repository" type:"structure"` + // A PackageVersionError object that contains a map of errors codes for the + // deleted package that failed. The possible error codes are: + // + // * ALREADY_EXISTS + // + // * MISMATCHED_REVISION + // + // * MISMATCHED_STATUS + // + // * NOT_ALLOWED + // + // * NOT_FOUND + // + // * SKIPPED + FailedVersions map[string]*PackageVersionError `locationName:"failedVersions" type:"map"` + + // A list of the package versions that were successfully deleted. The status + // of every successful version will be Deleted. + SuccessfulVersions map[string]*SuccessfulPackageVersionInfo `locationName:"successfulVersions" type:"map"` } // String returns the string representation. @@ -4352,7 +7098,7 @@ type AssociateExternalConnectionOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AssociateExternalConnectionOutput) String() string { +func (s DeletePackageVersionsOutput) String() string { return awsutil.Prettify(s) } @@ -4361,28 +7107,38 @@ func (s AssociateExternalConnectionOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s AssociateExternalConnectionOutput) GoString() string { +func (s DeletePackageVersionsOutput) GoString() string { return s.String() } -// SetRepository sets the Repository field's value. -func (s *AssociateExternalConnectionOutput) SetRepository(v *RepositoryDescription) *AssociateExternalConnectionOutput { - s.Repository = v +// SetFailedVersions sets the FailedVersions field's value. +func (s *DeletePackageVersionsOutput) SetFailedVersions(v map[string]*PackageVersionError) *DeletePackageVersionsOutput { + s.FailedVersions = v return s } -// The operation did not succeed because prerequisites are not met. -type ConflictException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` +// SetSuccessfulVersions sets the SuccessfulVersions field's value. +func (s *DeletePackageVersionsOutput) SetSuccessfulVersions(v map[string]*SuccessfulPackageVersionInfo) *DeletePackageVersionsOutput { + s.SuccessfulVersions = v + return s +} - Message_ *string `locationName:"message" type:"string"` +type DeleteRepositoryInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The ID of the resource. - ResourceId *string `locationName:"resourceId" type:"string"` + // The name of the domain that contains the repository to delete. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` - // The type of Amazon Web Services resource. - ResourceType *string `locationName:"resourceType" type:"string" enum:"ResourceType"` + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The name of the repository to delete. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -4390,7 +7146,7 @@ type ConflictException struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ConflictException) String() string { +func (s DeleteRepositoryInput) String() string { return awsutil.Prettify(s) } @@ -4399,63 +7155,89 @@ func (s ConflictException) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ConflictException) GoString() string { +func (s DeleteRepositoryInput) GoString() string { return s.String() } -func newErrorConflictException(v protocol.ResponseMetadata) error { - return &ConflictException{ - RespMetadata: v, +// Validate inspects the fields of the type to determine if they are valid. +func (s *DeleteRepositoryInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteRepositoryInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams } + return nil } -// Code returns the exception type name. -func (s *ConflictException) Code() string { - return "ConflictException" +// SetDomain sets the Domain field's value. +func (s *DeleteRepositoryInput) SetDomain(v string) *DeleteRepositoryInput { + s.Domain = &v + return s } -// Message returns the exception's message. -func (s *ConflictException) Message() string { - if s.Message_ != nil { - return *s.Message_ - } - return "" +// SetDomainOwner sets the DomainOwner field's value. +func (s *DeleteRepositoryInput) SetDomainOwner(v string) *DeleteRepositoryInput { + s.DomainOwner = &v + return s } -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *ConflictException) OrigErr() error { - return nil +// SetRepository sets the Repository field's value. +func (s *DeleteRepositoryInput) SetRepository(v string) *DeleteRepositoryInput { + s.Repository = &v + return s } -func (s *ConflictException) Error() string { - return fmt.Sprintf("%s: %s\n%s", s.Code(), s.Message(), s.String()) +type DeleteRepositoryOutput struct { + _ struct{} `type:"structure"` + + // Information about the deleted repository after processing the request. + Repository *RepositoryDescription `locationName:"repository" type:"structure"` } -// Status code returns the HTTP status code for the request's response error. -func (s *ConflictException) StatusCode() int { - return s.RespMetadata.StatusCode +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteRepositoryOutput) String() string { + return awsutil.Prettify(s) } -// RequestID returns the service's response RequestID for request. -func (s *ConflictException) RequestID() string { - return s.RespMetadata.RequestID +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteRepositoryOutput) GoString() string { + return s.String() } -type CopyPackageVersionsInput struct { - _ struct{} `type:"structure"` - - // Set to true to overwrite a package version that already exists in the destination - // repository. If set to false and the package version already exists in the - // destination repository, the package version is returned in the failedVersions - // field of the response with an ALREADY_EXISTS error code. - AllowOverwrite *bool `locationName:"allowOverwrite" type:"boolean"` +// SetRepository sets the Repository field's value. +func (s *DeleteRepositoryOutput) SetRepository(v *RepositoryDescription) *DeleteRepositoryOutput { + s.Repository = v + return s +} - // The name of the repository into which package versions are copied. - // - // DestinationRepository is a required field - DestinationRepository *string `location:"querystring" locationName:"destination-repository" min:"2" type:"string" required:"true"` +type DeleteRepositoryPermissionsPolicyInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the source and destination repositories. + // The name of the domain that contains the repository associated with the resource + // policy to be deleted. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -4464,52 +7246,16 @@ type CopyPackageVersionsInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The format of the package versions to be copied. - // - // Format is a required field - Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - - // Set to true to copy packages from repositories that are upstream from the - // source repository to the destination repository. The default setting is false. - // For more information, see Working with upstream repositories (https://docs.aws.amazon.com/codeartifact/latest/ug/repos-upstream.html). - IncludeFromUpstream *bool `locationName:"includeFromUpstream" type:"boolean"` - - // The namespace of the package versions to be copied. The package version component - // that specifies its namespace depends on its type. For example: - // - // * The namespace of a Maven package version is its groupId. The namespace - // is required when copying Maven package versions. - // - // * The namespace of an npm package version is its scope. - // - // * Python and NuGet package versions do not contain a corresponding component, - // package versions of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. - Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - - // The name of the package that contains the versions to be copied. - // - // Package is a required field - Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` - - // The name of the repository that contains the package versions to be copied. - // - // SourceRepository is a required field - SourceRepository *string `location:"querystring" locationName:"source-repository" min:"2" type:"string" required:"true"` - - // A list of key-value pairs. The keys are package versions and the values are - // package version revisions. A CopyPackageVersion operation succeeds if the - // specified versions in the source repository match the specified package version - // revision. - // - // You must specify versions or versionRevisions. You cannot specify both. - VersionRevisions map[string]*string `locationName:"versionRevisions" type:"map"` + // The revision of the repository's resource policy to be deleted. This revision + // is used for optimistic locking, which prevents others from accidentally overwriting + // your changes to the repository's resource policy. + PolicyRevision *string `location:"querystring" locationName:"policy-revision" min:"1" type:"string"` - // The versions of the package to be copied. + // The name of the repository that is associated with the resource policy to + // be deleted // - // You must specify versions or versionRevisions. You cannot specify both. - Versions []*string `locationName:"versions" type:"list"` + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -4517,7 +7263,7 @@ type CopyPackageVersionsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CopyPackageVersionsInput) String() string { +func (s DeleteRepositoryPermissionsPolicyInput) String() string { return awsutil.Prettify(s) } @@ -4526,19 +7272,13 @@ func (s CopyPackageVersionsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CopyPackageVersionsInput) GoString() string { +func (s DeleteRepositoryPermissionsPolicyInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CopyPackageVersionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CopyPackageVersionsInput"} - if s.DestinationRepository == nil { - invalidParams.Add(request.NewErrParamRequired("DestinationRepository")) - } - if s.DestinationRepository != nil && len(*s.DestinationRepository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("DestinationRepository", 2)) - } +func (s *DeleteRepositoryPermissionsPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DeleteRepositoryPermissionsPolicyInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -4548,23 +7288,14 @@ func (s *CopyPackageVersionsInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Format == nil { - invalidParams.Add(request.NewErrParamRequired("Format")) - } - if s.Namespace != nil && len(*s.Namespace) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) - } - if s.Package == nil { - invalidParams.Add(request.NewErrParamRequired("Package")) - } - if s.Package != nil && len(*s.Package) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + if s.PolicyRevision != nil && len(*s.PolicyRevision) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PolicyRevision", 1)) } - if s.SourceRepository == nil { - invalidParams.Add(request.NewErrParamRequired("SourceRepository")) + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) } - if s.SourceRepository != nil && len(*s.SourceRepository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("SourceRepository", 2)) + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) } if invalidParams.Len() > 0 { @@ -4573,93 +7304,129 @@ func (s *CopyPackageVersionsInput) Validate() error { return nil } -// SetAllowOverwrite sets the AllowOverwrite field's value. -func (s *CopyPackageVersionsInput) SetAllowOverwrite(v bool) *CopyPackageVersionsInput { - s.AllowOverwrite = &v - return s -} - -// SetDestinationRepository sets the DestinationRepository field's value. -func (s *CopyPackageVersionsInput) SetDestinationRepository(v string) *CopyPackageVersionsInput { - s.DestinationRepository = &v - return s -} - // SetDomain sets the Domain field's value. -func (s *CopyPackageVersionsInput) SetDomain(v string) *CopyPackageVersionsInput { +func (s *DeleteRepositoryPermissionsPolicyInput) SetDomain(v string) *DeleteRepositoryPermissionsPolicyInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *CopyPackageVersionsInput) SetDomainOwner(v string) *CopyPackageVersionsInput { +func (s *DeleteRepositoryPermissionsPolicyInput) SetDomainOwner(v string) *DeleteRepositoryPermissionsPolicyInput { s.DomainOwner = &v return s } -// SetFormat sets the Format field's value. -func (s *CopyPackageVersionsInput) SetFormat(v string) *CopyPackageVersionsInput { - s.Format = &v +// SetPolicyRevision sets the PolicyRevision field's value. +func (s *DeleteRepositoryPermissionsPolicyInput) SetPolicyRevision(v string) *DeleteRepositoryPermissionsPolicyInput { + s.PolicyRevision = &v return s } -// SetIncludeFromUpstream sets the IncludeFromUpstream field's value. -func (s *CopyPackageVersionsInput) SetIncludeFromUpstream(v bool) *CopyPackageVersionsInput { - s.IncludeFromUpstream = &v +// SetRepository sets the Repository field's value. +func (s *DeleteRepositoryPermissionsPolicyInput) SetRepository(v string) *DeleteRepositoryPermissionsPolicyInput { + s.Repository = &v return s } -// SetNamespace sets the Namespace field's value. -func (s *CopyPackageVersionsInput) SetNamespace(v string) *CopyPackageVersionsInput { - s.Namespace = &v - return s -} +type DeleteRepositoryPermissionsPolicyOutput struct { + _ struct{} `type:"structure"` -// SetPackage sets the Package field's value. -func (s *CopyPackageVersionsInput) SetPackage(v string) *CopyPackageVersionsInput { - s.Package = &v - return s + // Information about the deleted policy after processing the request. + Policy *ResourcePolicy `locationName:"policy" type:"structure"` } -// SetSourceRepository sets the SourceRepository field's value. -func (s *CopyPackageVersionsInput) SetSourceRepository(v string) *CopyPackageVersionsInput { - s.SourceRepository = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteRepositoryPermissionsPolicyOutput) String() string { + return awsutil.Prettify(s) } -// SetVersionRevisions sets the VersionRevisions field's value. -func (s *CopyPackageVersionsInput) SetVersionRevisions(v map[string]*string) *CopyPackageVersionsInput { - s.VersionRevisions = v - return s +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DeleteRepositoryPermissionsPolicyOutput) GoString() string { + return s.String() } -// SetVersions sets the Versions field's value. -func (s *CopyPackageVersionsInput) SetVersions(v []*string) *CopyPackageVersionsInput { - s.Versions = v +// SetPolicy sets the Policy field's value. +func (s *DeleteRepositoryPermissionsPolicyOutput) SetPolicy(v *ResourcePolicy) *DeleteRepositoryPermissionsPolicyOutput { + s.Policy = v return s } -type CopyPackageVersionsOutput struct { - _ struct{} `type:"structure"` +type DescribeDomainInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // A map of package versions that failed to copy and their error codes. The - // possible error codes are in the PackageVersionError data type. They are: - // - // * ALREADY_EXISTS - // - // * MISMATCHED_REVISION - // - // * MISMATCHED_STATUS - // - // * NOT_ALLOWED - // - // * NOT_FOUND + // A string that specifies the name of the requested domain. // - // * SKIPPED - FailedVersions map[string]*PackageVersionError `locationName:"failedVersions" type:"map"` + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DescribeDomainInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s DescribeDomainInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *DescribeDomainInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribeDomainInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetDomain sets the Domain field's value. +func (s *DescribeDomainInput) SetDomain(v string) *DescribeDomainInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *DescribeDomainInput) SetDomainOwner(v string) *DescribeDomainInput { + s.DomainOwner = &v + return s +} - // A list of the package versions that were successfully copied to your repository. - SuccessfulVersions map[string]*SuccessfulPackageVersionInfo `locationName:"successfulVersions" type:"map"` +type DescribeDomainOutput struct { + _ struct{} `type:"structure"` + + // Information about a domain. A domain is a container for repositories. When + // you create a domain, it is empty until you add one or more repositories. + Domain *DomainDescription `locationName:"domain" type:"structure"` } // String returns the string representation. @@ -4667,7 +7434,7 @@ type CopyPackageVersionsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CopyPackageVersionsOutput) String() string { +func (s DescribeDomainOutput) String() string { return awsutil.Prettify(s) } @@ -4676,50 +7443,32 @@ func (s CopyPackageVersionsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CopyPackageVersionsOutput) GoString() string { +func (s DescribeDomainOutput) GoString() string { return s.String() } -// SetFailedVersions sets the FailedVersions field's value. -func (s *CopyPackageVersionsOutput) SetFailedVersions(v map[string]*PackageVersionError) *CopyPackageVersionsOutput { - s.FailedVersions = v - return s -} - -// SetSuccessfulVersions sets the SuccessfulVersions field's value. -func (s *CopyPackageVersionsOutput) SetSuccessfulVersions(v map[string]*SuccessfulPackageVersionInfo) *CopyPackageVersionsOutput { - s.SuccessfulVersions = v +// SetDomain sets the Domain field's value. +func (s *DescribeDomainOutput) SetDomain(v *DomainDescription) *DescribeDomainOutput { + s.Domain = v return s } -type CreateDomainInput struct { - _ struct{} `type:"structure"` +type DescribePackageGroupInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain to create. All domain names in an Amazon Web Services - // Region that are in the same Amazon Web Services account must be unique. The - // domain name is used as the prefix in DNS hostnames. Do not use sensitive - // information in a domain name because it is publicly discoverable. + // The name of the domain that contains the package group. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` - // The encryption key for the domain. This is used to encrypt content stored - // in a domain. An encryption key can be a key ID, a key Amazon Resource Name - // (ARN), a key alias, or a key alias ARN. To specify an encryptionKey, your - // IAM role must have kms:DescribeKey and kms:CreateGrant permissions on the - // encryption key that is used. For more information, see DescribeKey (https://docs.aws.amazon.com/kms/latest/APIReference/API_DescribeKey.html#API_DescribeKey_RequestSyntax) - // in the Key Management Service API Reference and Key Management Service API - // Permissions Reference (https://docs.aws.amazon.com/kms/latest/developerguide/kms-api-permissions-reference.html) - // in the Key Management Service Developer Guide. - // - // CodeArtifact supports only symmetric CMKs. Do not associate an asymmetric - // CMK with your domain. For more information, see Using symmetric and asymmetric - // keys (https://docs.aws.amazon.com/kms/latest/developerguide/symmetric-asymmetric.html) - // in the Key Management Service Developer Guide. - EncryptionKey *string `locationName:"encryptionKey" min:"1" type:"string"` + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // One or more tag key-value pairs for the domain. - Tags []*Tag `locationName:"tags" type:"list"` + // The pattern of the requested package group. + // + // PackageGroup is a required field + PackageGroup *string `location:"querystring" locationName:"package-group" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -4727,7 +7476,7 @@ type CreateDomainInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateDomainInput) String() string { +func (s DescribePackageGroupInput) String() string { return awsutil.Prettify(s) } @@ -4736,31 +7485,27 @@ func (s CreateDomainInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateDomainInput) GoString() string { +func (s DescribePackageGroupInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CreateDomainInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateDomainInput"} +func (s *DescribePackageGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribePackageGroupInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } if s.Domain != nil && len(*s.Domain) < 2 { invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) } - if s.EncryptionKey != nil && len(*s.EncryptionKey) < 1 { - invalidParams.Add(request.NewErrParamMinLen("EncryptionKey", 1)) + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Tags != nil { - for i, v := range s.Tags { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) - } - } + if s.PackageGroup == nil { + invalidParams.Add(request.NewErrParamRequired("PackageGroup")) + } + if s.PackageGroup != nil && len(*s.PackageGroup) < 2 { + invalidParams.Add(request.NewErrParamMinLen("PackageGroup", 2)) } if invalidParams.Len() > 0 { @@ -4770,28 +7515,29 @@ func (s *CreateDomainInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *CreateDomainInput) SetDomain(v string) *CreateDomainInput { +func (s *DescribePackageGroupInput) SetDomain(v string) *DescribePackageGroupInput { s.Domain = &v return s } -// SetEncryptionKey sets the EncryptionKey field's value. -func (s *CreateDomainInput) SetEncryptionKey(v string) *CreateDomainInput { - s.EncryptionKey = &v +// SetDomainOwner sets the DomainOwner field's value. +func (s *DescribePackageGroupInput) SetDomainOwner(v string) *DescribePackageGroupInput { + s.DomainOwner = &v return s } -// SetTags sets the Tags field's value. -func (s *CreateDomainInput) SetTags(v []*Tag) *CreateDomainInput { - s.Tags = v +// SetPackageGroup sets the PackageGroup field's value. +func (s *DescribePackageGroupInput) SetPackageGroup(v string) *DescribePackageGroupInput { + s.PackageGroup = &v return s } -type CreateDomainOutput struct { +type DescribePackageGroupOutput struct { _ struct{} `type:"structure"` - // Contains information about the created domain after processing the request. - Domain *DomainDescription `locationName:"domain" type:"structure"` + // A PackageGroupDescription (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageGroupDescription.html) + // object that contains information about the requested package group. + PackageGroup *PackageGroupDescription `locationName:"packageGroup" type:"structure"` } // String returns the string representation. @@ -4799,7 +7545,7 @@ type CreateDomainOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateDomainOutput) String() string { +func (s DescribePackageGroupOutput) String() string { return awsutil.Prettify(s) } @@ -4808,23 +7554,20 @@ func (s CreateDomainOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateDomainOutput) GoString() string { +func (s DescribePackageGroupOutput) GoString() string { return s.String() } -// SetDomain sets the Domain field's value. -func (s *CreateDomainOutput) SetDomain(v *DomainDescription) *CreateDomainOutput { - s.Domain = v +// SetPackageGroup sets the PackageGroup field's value. +func (s *DescribePackageGroupOutput) SetPackageGroup(v *PackageGroupDescription) *DescribePackageGroupOutput { + s.PackageGroup = v return s } -type CreateRepositoryInput struct { - _ struct{} `type:"structure"` - - // A description of the created repository. - Description *string `locationName:"description" type:"string"` +type DescribePackageInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the created repository. + // The name of the domain that contains the repository that contains the package. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -4833,19 +7576,41 @@ type CreateRepositoryInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The name of the repository to create. + // A format that specifies the type of the requested package. // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - // One or more tag key-value pairs for the repository. - Tags []*Tag `locationName:"tags" type:"list"` + // The namespace of the requested package. The package component that specifies + // its namespace depends on its type. For example: + // + // The namespace is required when requesting packages of the following formats: + // + // * Maven + // + // * Swift + // + // * generic + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - // A list of upstream repositories to associate with the repository. The order - // of the upstream repositories in the list determines their priority order - // when CodeArtifact looks for a requested package version. For more information, - // see Working with upstream repositories (https://docs.aws.amazon.com/codeartifact/latest/ug/repos-upstream.html). - Upstreams []*UpstreamRepository `locationName:"upstreams" type:"list"` + // The name of the requested package. + // + // Package is a required field + Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + + // The name of the repository that contains the requested package. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -4853,7 +7618,7 @@ type CreateRepositoryInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateRepositoryInput) String() string { +func (s DescribePackageInput) String() string { return awsutil.Prettify(s) } @@ -4862,13 +7627,13 @@ func (s CreateRepositoryInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateRepositoryInput) GoString() string { +func (s DescribePackageInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *CreateRepositoryInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "CreateRepositoryInput"} +func (s *DescribePackageInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribePackageInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -4878,32 +7643,24 @@ func (s *CreateRepositoryInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) + } + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) + } + if s.Package == nil { + invalidParams.Add(request.NewErrParamRequired("Package")) + } + if s.Package != nil && len(*s.Package) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + } if s.Repository == nil { invalidParams.Add(request.NewErrParamRequired("Repository")) } if s.Repository != nil && len(*s.Repository) < 2 { invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) } - if s.Tags != nil { - for i, v := range s.Tags { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Tags", i), err.(request.ErrInvalidParams)) - } - } - } - if s.Upstreams != nil { - for i, v := range s.Upstreams { - if v == nil { - continue - } - if err := v.Validate(); err != nil { - invalidParams.AddNested(fmt.Sprintf("%s[%v]", "Upstreams", i), err.(request.ErrInvalidParams)) - } - } - } if invalidParams.Len() > 0 { return invalidParams @@ -4911,47 +7668,50 @@ func (s *CreateRepositoryInput) Validate() error { return nil } -// SetDescription sets the Description field's value. -func (s *CreateRepositoryInput) SetDescription(v string) *CreateRepositoryInput { - s.Description = &v - return s -} - // SetDomain sets the Domain field's value. -func (s *CreateRepositoryInput) SetDomain(v string) *CreateRepositoryInput { +func (s *DescribePackageInput) SetDomain(v string) *DescribePackageInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *CreateRepositoryInput) SetDomainOwner(v string) *CreateRepositoryInput { +func (s *DescribePackageInput) SetDomainOwner(v string) *DescribePackageInput { s.DomainOwner = &v return s } -// SetRepository sets the Repository field's value. -func (s *CreateRepositoryInput) SetRepository(v string) *CreateRepositoryInput { - s.Repository = &v +// SetFormat sets the Format field's value. +func (s *DescribePackageInput) SetFormat(v string) *DescribePackageInput { + s.Format = &v return s } -// SetTags sets the Tags field's value. -func (s *CreateRepositoryInput) SetTags(v []*Tag) *CreateRepositoryInput { - s.Tags = v +// SetNamespace sets the Namespace field's value. +func (s *DescribePackageInput) SetNamespace(v string) *DescribePackageInput { + s.Namespace = &v return s } -// SetUpstreams sets the Upstreams field's value. -func (s *CreateRepositoryInput) SetUpstreams(v []*UpstreamRepository) *CreateRepositoryInput { - s.Upstreams = v +// SetPackage sets the Package field's value. +func (s *DescribePackageInput) SetPackage(v string) *DescribePackageInput { + s.Package = &v return s } -type CreateRepositoryOutput struct { +// SetRepository sets the Repository field's value. +func (s *DescribePackageInput) SetRepository(v string) *DescribePackageInput { + s.Repository = &v + return s +} + +type DescribePackageOutput struct { _ struct{} `type:"structure"` - // Information about the created repository after processing the request. - Repository *RepositoryDescription `locationName:"repository" type:"structure"` + // A PackageDescription (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageDescription.html) + // object that contains information about the requested package. + // + // Package is a required field + Package *PackageDescription `locationName:"package" type:"structure" required:"true"` } // String returns the string representation. @@ -4959,7 +7719,7 @@ type CreateRepositoryOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateRepositoryOutput) String() string { +func (s DescribePackageOutput) String() string { return awsutil.Prettify(s) } @@ -4968,27 +7728,70 @@ func (s CreateRepositoryOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s CreateRepositoryOutput) GoString() string { +func (s DescribePackageOutput) GoString() string { return s.String() } -// SetRepository sets the Repository field's value. -func (s *CreateRepositoryOutput) SetRepository(v *RepositoryDescription) *CreateRepositoryOutput { - s.Repository = v +// SetPackage sets the Package field's value. +func (s *DescribePackageOutput) SetPackage(v *PackageDescription) *DescribePackageOutput { + s.Package = v return s } -type DeleteDomainInput struct { - _ struct{} `type:"structure" nopayload:"true"` +type DescribePackageVersionInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The name of the domain that contains the repository that contains the package + // version. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // A format that specifies the type of the requested package version. + // + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` + + // The namespace of the requested package version. The package component that + // specifies its namespace depends on its type. For example: + // + // The namespace is required when requesting package versions of the following + // formats: + // + // * Maven + // + // * Swift + // + // * generic + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` + + // The name of the requested package version. + // + // Package is a required field + Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` - // The name of the domain to delete. + // A string that contains the package version (for example, 3.5.2). // - // Domain is a required field - Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + // PackageVersion is a required field + PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` - // The 12-digit account number of the Amazon Web Services account that owns - // the domain. It does not include dashes or spaces. - DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + // The name of the repository that contains the package version. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -4996,7 +7799,7 @@ type DeleteDomainInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDomainInput) String() string { +func (s DescribePackageVersionInput) String() string { return awsutil.Prettify(s) } @@ -5005,13 +7808,13 @@ func (s DeleteDomainInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDomainInput) GoString() string { +func (s DescribePackageVersionInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteDomainInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteDomainInput"} +func (s *DescribePackageVersionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribePackageVersionInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -5021,6 +7824,30 @@ func (s *DeleteDomainInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) + } + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) + } + if s.Package == nil { + invalidParams.Add(request.NewErrParamRequired("Package")) + } + if s.Package != nil && len(*s.Package) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + } + if s.PackageVersion == nil { + invalidParams.Add(request.NewErrParamRequired("PackageVersion")) + } + if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) + } + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + } if invalidParams.Len() > 0 { return invalidParams @@ -5029,22 +7856,55 @@ func (s *DeleteDomainInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *DeleteDomainInput) SetDomain(v string) *DeleteDomainInput { +func (s *DescribePackageVersionInput) SetDomain(v string) *DescribePackageVersionInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *DeleteDomainInput) SetDomainOwner(v string) *DeleteDomainInput { +func (s *DescribePackageVersionInput) SetDomainOwner(v string) *DescribePackageVersionInput { s.DomainOwner = &v return s } -type DeleteDomainOutput struct { +// SetFormat sets the Format field's value. +func (s *DescribePackageVersionInput) SetFormat(v string) *DescribePackageVersionInput { + s.Format = &v + return s +} + +// SetNamespace sets the Namespace field's value. +func (s *DescribePackageVersionInput) SetNamespace(v string) *DescribePackageVersionInput { + s.Namespace = &v + return s +} + +// SetPackage sets the Package field's value. +func (s *DescribePackageVersionInput) SetPackage(v string) *DescribePackageVersionInput { + s.Package = &v + return s +} + +// SetPackageVersion sets the PackageVersion field's value. +func (s *DescribePackageVersionInput) SetPackageVersion(v string) *DescribePackageVersionInput { + s.PackageVersion = &v + return s +} + +// SetRepository sets the Repository field's value. +func (s *DescribePackageVersionInput) SetRepository(v string) *DescribePackageVersionInput { + s.Repository = &v + return s +} + +type DescribePackageVersionOutput struct { _ struct{} `type:"structure"` - // Contains information about the deleted domain after processing the request. - Domain *DomainDescription `locationName:"domain" type:"structure"` + // A PackageVersionDescription (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionDescription.html) + // object that contains information about the requested package version. + // + // PackageVersion is a required field + PackageVersion *PackageVersionDescription `locationName:"packageVersion" type:"structure" required:"true"` } // String returns the string representation. @@ -5052,7 +7912,7 @@ type DeleteDomainOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDomainOutput) String() string { +func (s DescribePackageVersionOutput) String() string { return awsutil.Prettify(s) } @@ -5061,20 +7921,20 @@ func (s DeleteDomainOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDomainOutput) GoString() string { +func (s DescribePackageVersionOutput) GoString() string { return s.String() } -// SetDomain sets the Domain field's value. -func (s *DeleteDomainOutput) SetDomain(v *DomainDescription) *DeleteDomainOutput { - s.Domain = v +// SetPackageVersion sets the PackageVersion field's value. +func (s *DescribePackageVersionOutput) SetPackageVersion(v *PackageVersionDescription) *DescribePackageVersionOutput { + s.PackageVersion = v return s } -type DeleteDomainPermissionsPolicyInput struct { +type DescribeRepositoryInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain associated with the resource policy to be deleted. + // The name of the domain that contains the repository to describe. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -5083,10 +7943,10 @@ type DeleteDomainPermissionsPolicyInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The current revision of the resource policy to be deleted. This revision - // is used for optimistic locking, which prevents others from overwriting your - // changes to the domain's resource policy. - PolicyRevision *string `location:"querystring" locationName:"policy-revision" min:"1" type:"string"` + // A string that specifies the name of the requested repository. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -5094,7 +7954,7 @@ type DeleteDomainPermissionsPolicyInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDomainPermissionsPolicyInput) String() string { +func (s DescribeRepositoryInput) String() string { return awsutil.Prettify(s) } @@ -5103,13 +7963,13 @@ func (s DeleteDomainPermissionsPolicyInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDomainPermissionsPolicyInput) GoString() string { +func (s DescribeRepositoryInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteDomainPermissionsPolicyInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteDomainPermissionsPolicyInput"} +func (s *DescribeRepositoryInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DescribeRepositoryInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -5119,8 +7979,11 @@ func (s *DeleteDomainPermissionsPolicyInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.PolicyRevision != nil && len(*s.PolicyRevision) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PolicyRevision", 1)) + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) } if invalidParams.Len() > 0 { @@ -5130,28 +7993,28 @@ func (s *DeleteDomainPermissionsPolicyInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *DeleteDomainPermissionsPolicyInput) SetDomain(v string) *DeleteDomainPermissionsPolicyInput { +func (s *DescribeRepositoryInput) SetDomain(v string) *DescribeRepositoryInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *DeleteDomainPermissionsPolicyInput) SetDomainOwner(v string) *DeleteDomainPermissionsPolicyInput { +func (s *DescribeRepositoryInput) SetDomainOwner(v string) *DescribeRepositoryInput { s.DomainOwner = &v return s } -// SetPolicyRevision sets the PolicyRevision field's value. -func (s *DeleteDomainPermissionsPolicyInput) SetPolicyRevision(v string) *DeleteDomainPermissionsPolicyInput { - s.PolicyRevision = &v +// SetRepository sets the Repository field's value. +func (s *DescribeRepositoryInput) SetRepository(v string) *DescribeRepositoryInput { + s.Repository = &v return s } -type DeleteDomainPermissionsPolicyOutput struct { +type DescribeRepositoryOutput struct { _ struct{} `type:"structure"` - // Information about the deleted resource policy after processing the request. - Policy *ResourcePolicy `locationName:"policy" type:"structure"` + // A RepositoryDescription object that contains the requested repository information. + Repository *RepositoryDescription `locationName:"repository" type:"structure"` } // String returns the string representation. @@ -5159,7 +8022,7 @@ type DeleteDomainPermissionsPolicyOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDomainPermissionsPolicyOutput) String() string { +func (s DescribeRepositoryOutput) String() string { return awsutil.Prettify(s) } @@ -5168,20 +8031,21 @@ func (s DeleteDomainPermissionsPolicyOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteDomainPermissionsPolicyOutput) GoString() string { +func (s DescribeRepositoryOutput) GoString() string { return s.String() } -// SetPolicy sets the Policy field's value. -func (s *DeleteDomainPermissionsPolicyOutput) SetPolicy(v *ResourcePolicy) *DeleteDomainPermissionsPolicyOutput { - s.Policy = v +// SetRepository sets the Repository field's value. +func (s *DescribeRepositoryOutput) SetRepository(v *RepositoryDescription) *DescribeRepositoryOutput { + s.Repository = v return s } -type DeletePackageInput struct { +type DisassociateExternalConnectionInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the package to delete. + // The name of the domain that contains the repository from which to remove + // the external repository. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -5190,31 +8054,12 @@ type DeletePackageInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The format of the requested package to delete. - // - // Format is a required field - Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - - // The namespace of the package to delete. The package component that specifies - // its namespace depends on its type. For example: - // - // * The namespace of a Maven package is its groupId. The namespace is required - // when deleting Maven package versions. - // - // * The namespace of an npm package is its scope. - // - // * Python and NuGet packages do not contain corresponding components, packages - // of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. - Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - - // The name of the package to delete. + // The name of the external connection to be removed from the repository. // - // Package is a required field - Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + // ExternalConnection is a required field + ExternalConnection *string `location:"querystring" locationName:"external-connection" min:"2" type:"string" required:"true"` - // The name of the repository that contains the package to delete. + // The name of the repository from which the external connection will be removed. // // Repository is a required field Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` @@ -5225,7 +8070,7 @@ type DeletePackageInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeletePackageInput) String() string { +func (s DisassociateExternalConnectionInput) String() string { return awsutil.Prettify(s) } @@ -5234,13 +8079,13 @@ func (s DeletePackageInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeletePackageInput) GoString() string { +func (s DisassociateExternalConnectionInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeletePackageInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeletePackageInput"} +func (s *DisassociateExternalConnectionInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DisassociateExternalConnectionInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -5250,17 +8095,11 @@ func (s *DeletePackageInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Format == nil { - invalidParams.Add(request.NewErrParamRequired("Format")) - } - if s.Namespace != nil && len(*s.Namespace) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) - } - if s.Package == nil { - invalidParams.Add(request.NewErrParamRequired("Package")) + if s.ExternalConnection == nil { + invalidParams.Add(request.NewErrParamRequired("ExternalConnection")) } - if s.Package != nil && len(*s.Package) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + if s.ExternalConnection != nil && len(*s.ExternalConnection) < 2 { + invalidParams.Add(request.NewErrParamMinLen("ExternalConnection", 2)) } if s.Repository == nil { invalidParams.Add(request.NewErrParamRequired("Repository")) @@ -5276,46 +8115,34 @@ func (s *DeletePackageInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *DeletePackageInput) SetDomain(v string) *DeletePackageInput { +func (s *DisassociateExternalConnectionInput) SetDomain(v string) *DisassociateExternalConnectionInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *DeletePackageInput) SetDomainOwner(v string) *DeletePackageInput { +func (s *DisassociateExternalConnectionInput) SetDomainOwner(v string) *DisassociateExternalConnectionInput { s.DomainOwner = &v return s } -// SetFormat sets the Format field's value. -func (s *DeletePackageInput) SetFormat(v string) *DeletePackageInput { - s.Format = &v - return s -} - -// SetNamespace sets the Namespace field's value. -func (s *DeletePackageInput) SetNamespace(v string) *DeletePackageInput { - s.Namespace = &v - return s -} - -// SetPackage sets the Package field's value. -func (s *DeletePackageInput) SetPackage(v string) *DeletePackageInput { - s.Package = &v +// SetExternalConnection sets the ExternalConnection field's value. +func (s *DisassociateExternalConnectionInput) SetExternalConnection(v string) *DisassociateExternalConnectionInput { + s.ExternalConnection = &v return s } // SetRepository sets the Repository field's value. -func (s *DeletePackageInput) SetRepository(v string) *DeletePackageInput { +func (s *DisassociateExternalConnectionInput) SetRepository(v string) *DisassociateExternalConnectionInput { s.Repository = &v return s } -type DeletePackageOutput struct { +type DisassociateExternalConnectionOutput struct { _ struct{} `type:"structure"` - // Details about a package, including its format, namespace, and name. - DeletedPackage *PackageSummary `locationName:"deletedPackage" type:"structure"` + // The repository associated with the removed external connection. + Repository *RepositoryDescription `locationName:"repository" type:"structure"` } // String returns the string representation. @@ -5323,7 +8150,7 @@ type DeletePackageOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeletePackageOutput) String() string { +func (s DisassociateExternalConnectionOutput) String() string { return awsutil.Prettify(s) } @@ -5332,20 +8159,20 @@ func (s DeletePackageOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeletePackageOutput) GoString() string { +func (s DisassociateExternalConnectionOutput) GoString() string { return s.String() } -// SetDeletedPackage sets the DeletedPackage field's value. -func (s *DeletePackageOutput) SetDeletedPackage(v *PackageSummary) *DeletePackageOutput { - s.DeletedPackage = v +// SetRepository sets the Repository field's value. +func (s *DisassociateExternalConnectionOutput) SetRepository(v *RepositoryDescription) *DisassociateExternalConnectionOutput { + s.Repository = v return s } -type DeletePackageVersionsInput struct { +type DisposePackageVersionsInput struct { _ struct{} `type:"structure"` - // The name of the domain that contains the package to delete. + // The name of the domain that contains the repository you want to dispose. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -5354,39 +8181,51 @@ type DeletePackageVersionsInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The expected status of the package version to delete. + // The expected status of the package version to dispose. ExpectedStatus *string `locationName:"expectedStatus" type:"string" enum:"PackageVersionStatus"` - // The format of the package versions to delete. + // A format that specifies the type of package versions you want to dispose. // // Format is a required field Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - // The namespace of the package versions to be deleted. The package version - // component that specifies its namespace depends on its type. For example: + // The namespace of the package versions to be disposed. The package component + // that specifies its namespace depends on its type. For example: // - // * The namespace of a Maven package version is its groupId. The namespace - // is required when deleting Maven package versions. + // The namespace is required when disposing package versions of the following + // formats: // - // * The namespace of an npm package version is its scope. + // * Maven // - // * Python and NuGet package versions do not contain a corresponding component, - // package versions of those formats do not have a namespace. + // * Swift + // + // * generic + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. // // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - // The name of the package with the versions to delete. + // The name of the package with the versions you want to dispose. // // Package is a required field Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` - // The name of the repository that contains the package versions to delete. + // The name of the repository that contains the package versions you want to + // dispose. // // Repository is a required field Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` - // An array of strings that specify the versions of the package to delete. + // The revisions of the package versions you want to dispose. + VersionRevisions map[string]*string `locationName:"versionRevisions" type:"map"` + + // The versions of the package you want to dispose. // // Versions is a required field Versions []*string `locationName:"versions" type:"list" required:"true"` @@ -5397,7 +8236,7 @@ type DeletePackageVersionsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeletePackageVersionsInput) String() string { +func (s DisposePackageVersionsInput) String() string { return awsutil.Prettify(s) } @@ -5406,13 +8245,13 @@ func (s DeletePackageVersionsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeletePackageVersionsInput) GoString() string { +func (s DisposePackageVersionsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DeletePackageVersionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeletePackageVersionsInput"} +func (s *DisposePackageVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "DisposePackageVersionsInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -5451,58 +8290,64 @@ func (s *DeletePackageVersionsInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *DeletePackageVersionsInput) SetDomain(v string) *DeletePackageVersionsInput { +func (s *DisposePackageVersionsInput) SetDomain(v string) *DisposePackageVersionsInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *DeletePackageVersionsInput) SetDomainOwner(v string) *DeletePackageVersionsInput { +func (s *DisposePackageVersionsInput) SetDomainOwner(v string) *DisposePackageVersionsInput { s.DomainOwner = &v return s } // SetExpectedStatus sets the ExpectedStatus field's value. -func (s *DeletePackageVersionsInput) SetExpectedStatus(v string) *DeletePackageVersionsInput { +func (s *DisposePackageVersionsInput) SetExpectedStatus(v string) *DisposePackageVersionsInput { s.ExpectedStatus = &v return s } // SetFormat sets the Format field's value. -func (s *DeletePackageVersionsInput) SetFormat(v string) *DeletePackageVersionsInput { +func (s *DisposePackageVersionsInput) SetFormat(v string) *DisposePackageVersionsInput { s.Format = &v return s } // SetNamespace sets the Namespace field's value. -func (s *DeletePackageVersionsInput) SetNamespace(v string) *DeletePackageVersionsInput { +func (s *DisposePackageVersionsInput) SetNamespace(v string) *DisposePackageVersionsInput { s.Namespace = &v return s } // SetPackage sets the Package field's value. -func (s *DeletePackageVersionsInput) SetPackage(v string) *DeletePackageVersionsInput { +func (s *DisposePackageVersionsInput) SetPackage(v string) *DisposePackageVersionsInput { s.Package = &v return s } // SetRepository sets the Repository field's value. -func (s *DeletePackageVersionsInput) SetRepository(v string) *DeletePackageVersionsInput { +func (s *DisposePackageVersionsInput) SetRepository(v string) *DisposePackageVersionsInput { s.Repository = &v return s } +// SetVersionRevisions sets the VersionRevisions field's value. +func (s *DisposePackageVersionsInput) SetVersionRevisions(v map[string]*string) *DisposePackageVersionsInput { + s.VersionRevisions = v + return s +} + // SetVersions sets the Versions field's value. -func (s *DeletePackageVersionsInput) SetVersions(v []*string) *DeletePackageVersionsInput { +func (s *DisposePackageVersionsInput) SetVersions(v []*string) *DisposePackageVersionsInput { s.Versions = v return s } -type DeletePackageVersionsOutput struct { +type DisposePackageVersionsOutput struct { _ struct{} `type:"structure"` // A PackageVersionError object that contains a map of errors codes for the - // deleted package that failed. The possible error codes are: + // disposed package versions that failed. The possible error codes are: // // * ALREADY_EXISTS // @@ -5517,8 +8362,7 @@ type DeletePackageVersionsOutput struct { // * SKIPPED FailedVersions map[string]*PackageVersionError `locationName:"failedVersions" type:"map"` - // A list of the package versions that were successfully deleted. The status - // of every successful version will be Deleted. + // A list of the package versions that were successfully disposed. SuccessfulVersions map[string]*SuccessfulPackageVersionInfo `locationName:"successfulVersions" type:"map"` } @@ -5527,7 +8371,7 @@ type DeletePackageVersionsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeletePackageVersionsOutput) String() string { +func (s DisposePackageVersionsOutput) String() string { return awsutil.Prettify(s) } @@ -5536,106 +8380,54 @@ func (s DeletePackageVersionsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeletePackageVersionsOutput) GoString() string { +func (s DisposePackageVersionsOutput) GoString() string { return s.String() } // SetFailedVersions sets the FailedVersions field's value. -func (s *DeletePackageVersionsOutput) SetFailedVersions(v map[string]*PackageVersionError) *DeletePackageVersionsOutput { +func (s *DisposePackageVersionsOutput) SetFailedVersions(v map[string]*PackageVersionError) *DisposePackageVersionsOutput { s.FailedVersions = v return s } // SetSuccessfulVersions sets the SuccessfulVersions field's value. -func (s *DeletePackageVersionsOutput) SetSuccessfulVersions(v map[string]*SuccessfulPackageVersionInfo) *DeletePackageVersionsOutput { +func (s *DisposePackageVersionsOutput) SetSuccessfulVersions(v map[string]*SuccessfulPackageVersionInfo) *DisposePackageVersionsOutput { s.SuccessfulVersions = v return s } -type DeleteRepositoryInput struct { - _ struct{} `type:"structure" nopayload:"true"` - - // The name of the domain that contains the repository to delete. - // - // Domain is a required field - Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` - - // The 12-digit account number of the Amazon Web Services account that owns - // the domain. It does not include dashes or spaces. - DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - - // The name of the repository to delete. - // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` -} +// Information about a domain. A domain is a container for repositories. When +// you create a domain, it is empty until you add one or more repositories. +type DomainDescription struct { + _ struct{} `type:"structure"` -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s DeleteRepositoryInput) String() string { - return awsutil.Prettify(s) -} + // The Amazon Resource Name (ARN) of the domain. + Arn *string `locationName:"arn" min:"1" type:"string"` -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s DeleteRepositoryInput) GoString() string { - return s.String() -} + // The total size of all assets in the domain. + AssetSizeBytes *int64 `locationName:"assetSizeBytes" type:"long"` -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteRepositoryInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteRepositoryInput"} - if s.Domain == nil { - invalidParams.Add(request.NewErrParamRequired("Domain")) - } - if s.Domain != nil && len(*s.Domain) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) - } - if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { - invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) - } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) - } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) - } + // A timestamp that represents the date and time the domain was created. + CreatedTime *time.Time `locationName:"createdTime" type:"timestamp"` - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} + // The ARN of an Key Management Service (KMS) key associated with a domain. + EncryptionKey *string `locationName:"encryptionKey" min:"1" type:"string"` -// SetDomain sets the Domain field's value. -func (s *DeleteRepositoryInput) SetDomain(v string) *DeleteRepositoryInput { - s.Domain = &v - return s -} + // The name of the domain. + Name *string `locationName:"name" min:"2" type:"string"` -// SetDomainOwner sets the DomainOwner field's value. -func (s *DeleteRepositoryInput) SetDomainOwner(v string) *DeleteRepositoryInput { - s.DomainOwner = &v - return s -} + // The Amazon Web Services account ID that owns the domain. + Owner *string `locationName:"owner" min:"12" type:"string"` -// SetRepository sets the Repository field's value. -func (s *DeleteRepositoryInput) SetRepository(v string) *DeleteRepositoryInput { - s.Repository = &v - return s -} + // The number of repositories in the domain. + RepositoryCount *int64 `locationName:"repositoryCount" type:"integer"` -type DeleteRepositoryOutput struct { - _ struct{} `type:"structure"` + // The Amazon Resource Name (ARN) of the Amazon S3 bucket that is used to store + // package assets in the domain. + S3BucketArn *string `locationName:"s3BucketArn" min:"1" type:"string"` - // Information about the deleted repository after processing the request. - Repository *RepositoryDescription `locationName:"repository" type:"structure"` + // The current status of a domain. + Status *string `locationName:"status" type:"string" enum:"DomainStatus"` } // String returns the string representation. @@ -5643,7 +8435,7 @@ type DeleteRepositoryOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteRepositoryOutput) String() string { +func (s DomainDescription) String() string { return awsutil.Prettify(s) } @@ -5652,116 +8444,83 @@ func (s DeleteRepositoryOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteRepositoryOutput) GoString() string { +func (s DomainDescription) GoString() string { return s.String() } -// SetRepository sets the Repository field's value. -func (s *DeleteRepositoryOutput) SetRepository(v *RepositoryDescription) *DeleteRepositoryOutput { - s.Repository = v +// SetArn sets the Arn field's value. +func (s *DomainDescription) SetArn(v string) *DomainDescription { + s.Arn = &v return s } -type DeleteRepositoryPermissionsPolicyInput struct { - _ struct{} `type:"structure" nopayload:"true"` - - // The name of the domain that contains the repository associated with the resource - // policy to be deleted. - // - // Domain is a required field - Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` - - // The 12-digit account number of the Amazon Web Services account that owns - // the domain. It does not include dashes or spaces. - DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - - // The revision of the repository's resource policy to be deleted. This revision - // is used for optimistic locking, which prevents others from accidentally overwriting - // your changes to the repository's resource policy. - PolicyRevision *string `location:"querystring" locationName:"policy-revision" min:"1" type:"string"` - - // The name of the repository that is associated with the resource policy to - // be deleted - // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` +// SetAssetSizeBytes sets the AssetSizeBytes field's value. +func (s *DomainDescription) SetAssetSizeBytes(v int64) *DomainDescription { + s.AssetSizeBytes = &v + return s } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s DeleteRepositoryPermissionsPolicyInput) String() string { - return awsutil.Prettify(s) +// SetCreatedTime sets the CreatedTime field's value. +func (s *DomainDescription) SetCreatedTime(v time.Time) *DomainDescription { + s.CreatedTime = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s DeleteRepositoryPermissionsPolicyInput) GoString() string { - return s.String() +// SetEncryptionKey sets the EncryptionKey field's value. +func (s *DomainDescription) SetEncryptionKey(v string) *DomainDescription { + s.EncryptionKey = &v + return s } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DeleteRepositoryPermissionsPolicyInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DeleteRepositoryPermissionsPolicyInput"} - if s.Domain == nil { - invalidParams.Add(request.NewErrParamRequired("Domain")) - } - if s.Domain != nil && len(*s.Domain) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) - } - if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { - invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) - } - if s.PolicyRevision != nil && len(*s.PolicyRevision) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PolicyRevision", 1)) - } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) - } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetName sets the Name field's value. +func (s *DomainDescription) SetName(v string) *DomainDescription { + s.Name = &v + return s } -// SetDomain sets the Domain field's value. -func (s *DeleteRepositoryPermissionsPolicyInput) SetDomain(v string) *DeleteRepositoryPermissionsPolicyInput { - s.Domain = &v +// SetOwner sets the Owner field's value. +func (s *DomainDescription) SetOwner(v string) *DomainDescription { + s.Owner = &v return s } -// SetDomainOwner sets the DomainOwner field's value. -func (s *DeleteRepositoryPermissionsPolicyInput) SetDomainOwner(v string) *DeleteRepositoryPermissionsPolicyInput { - s.DomainOwner = &v +// SetRepositoryCount sets the RepositoryCount field's value. +func (s *DomainDescription) SetRepositoryCount(v int64) *DomainDescription { + s.RepositoryCount = &v return s } -// SetPolicyRevision sets the PolicyRevision field's value. -func (s *DeleteRepositoryPermissionsPolicyInput) SetPolicyRevision(v string) *DeleteRepositoryPermissionsPolicyInput { - s.PolicyRevision = &v +// SetS3BucketArn sets the S3BucketArn field's value. +func (s *DomainDescription) SetS3BucketArn(v string) *DomainDescription { + s.S3BucketArn = &v return s } -// SetRepository sets the Repository field's value. -func (s *DeleteRepositoryPermissionsPolicyInput) SetRepository(v string) *DeleteRepositoryPermissionsPolicyInput { - s.Repository = &v +// SetStatus sets the Status field's value. +func (s *DomainDescription) SetStatus(v string) *DomainDescription { + s.Status = &v return s } -type DeleteRepositoryPermissionsPolicyOutput struct { +// Information about how a package originally entered the CodeArtifact domain. +// For packages published directly to CodeArtifact, the entry point is the repository +// it was published to. For packages ingested from an external repository, the +// entry point is the external connection that it was ingested from. An external +// connection is a CodeArtifact repository that is connected to an external +// repository such as the npm registry or NuGet gallery. +// +// If a package version exists in a repository and is updated, for example if +// a package of the same version is added with additional assets, the package +// version's DomainEntryPoint will not change from the original package version's +// value. +type DomainEntryPoint struct { _ struct{} `type:"structure"` - // Information about the deleted policy after processing the request. - Policy *ResourcePolicy `locationName:"policy" type:"structure"` + // The name of the external connection that a package was ingested from. + ExternalConnectionName *string `locationName:"externalConnectionName" min:"2" type:"string"` + + // The name of the repository that a package was originally published to. + RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"` } // String returns the string representation. @@ -5769,7 +8528,7 @@ type DeleteRepositoryPermissionsPolicyOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteRepositoryPermissionsPolicyOutput) String() string { +func (s DomainEntryPoint) String() string { return awsutil.Prettify(s) } @@ -5778,27 +8537,46 @@ func (s DeleteRepositoryPermissionsPolicyOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DeleteRepositoryPermissionsPolicyOutput) GoString() string { +func (s DomainEntryPoint) GoString() string { return s.String() } -// SetPolicy sets the Policy field's value. -func (s *DeleteRepositoryPermissionsPolicyOutput) SetPolicy(v *ResourcePolicy) *DeleteRepositoryPermissionsPolicyOutput { - s.Policy = v +// SetExternalConnectionName sets the ExternalConnectionName field's value. +func (s *DomainEntryPoint) SetExternalConnectionName(v string) *DomainEntryPoint { + s.ExternalConnectionName = &v return s } -type DescribeDomainInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// SetRepositoryName sets the RepositoryName field's value. +func (s *DomainEntryPoint) SetRepositoryName(v string) *DomainEntryPoint { + s.RepositoryName = &v + return s +} - // A string that specifies the name of the requested domain. - // - // Domain is a required field - Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` +// Information about a domain, including its name, Amazon Resource Name (ARN), +// and status. The ListDomains (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_ListDomains.html) +// operation returns a list of DomainSummary objects. +type DomainSummary struct { + _ struct{} `type:"structure"` + + // The ARN of the domain. + Arn *string `locationName:"arn" min:"1" type:"string"` + + // A timestamp that contains the date and time the domain was created. + CreatedTime *time.Time `locationName:"createdTime" type:"timestamp"` + + // The key used to encrypt the domain. + EncryptionKey *string `locationName:"encryptionKey" min:"1" type:"string"` + + // The name of the domain. + Name *string `locationName:"name" min:"2" type:"string"` // The 12-digit account number of the Amazon Web Services account that owns // the domain. It does not include dashes or spaces. - DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + Owner *string `locationName:"owner" min:"12" type:"string"` + + // A string that contains the status of the domain. + Status *string `locationName:"status" type:"string" enum:"DomainStatus"` } // String returns the string representation. @@ -5806,7 +8584,7 @@ type DescribeDomainInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribeDomainInput) String() string { +func (s DomainSummary) String() string { return awsutil.Prettify(s) } @@ -5815,77 +8593,51 @@ func (s DescribeDomainInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribeDomainInput) GoString() string { +func (s DomainSummary) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeDomainInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeDomainInput"} - if s.Domain == nil { - invalidParams.Add(request.NewErrParamRequired("Domain")) - } - if s.Domain != nil && len(*s.Domain) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) - } - if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { - invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetDomain sets the Domain field's value. -func (s *DescribeDomainInput) SetDomain(v string) *DescribeDomainInput { - s.Domain = &v +// SetArn sets the Arn field's value. +func (s *DomainSummary) SetArn(v string) *DomainSummary { + s.Arn = &v return s } -// SetDomainOwner sets the DomainOwner field's value. -func (s *DescribeDomainInput) SetDomainOwner(v string) *DescribeDomainInput { - s.DomainOwner = &v +// SetCreatedTime sets the CreatedTime field's value. +func (s *DomainSummary) SetCreatedTime(v time.Time) *DomainSummary { + s.CreatedTime = &v return s } -type DescribeDomainOutput struct { - _ struct{} `type:"structure"` - - // Information about a domain. A domain is a container for repositories. When - // you create a domain, it is empty until you add one or more repositories. - Domain *DomainDescription `locationName:"domain" type:"structure"` +// SetEncryptionKey sets the EncryptionKey field's value. +func (s *DomainSummary) SetEncryptionKey(v string) *DomainSummary { + s.EncryptionKey = &v + return s } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s DescribeDomainOutput) String() string { - return awsutil.Prettify(s) +// SetName sets the Name field's value. +func (s *DomainSummary) SetName(v string) *DomainSummary { + s.Name = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s DescribeDomainOutput) GoString() string { - return s.String() +// SetOwner sets the Owner field's value. +func (s *DomainSummary) SetOwner(v string) *DomainSummary { + s.Owner = &v + return s } -// SetDomain sets the Domain field's value. -func (s *DescribeDomainOutput) SetDomain(v *DomainDescription) *DescribeDomainOutput { - s.Domain = v +// SetStatus sets the Status field's value. +func (s *DomainSummary) SetStatus(v string) *DomainSummary { + s.Status = &v return s } -type DescribePackageInput struct { +type GetAssociatedPackageGroupInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository that contains the package. + // The name of the domain that contains the package from which to get the associated + // package group. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -5894,34 +8646,38 @@ type DescribePackageInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // A format that specifies the type of the requested package. + // The format of the package from which to get the associated package group. // // Format is a required field Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - // The namespace of the requested package. The package component that specifies - // its namespace depends on its type. For example: + // The namespace of the package from which to get the associated package group. + // The package component that specifies its namespace depends on its type. For + // example: + // + // The namespace is required when getting associated package groups from packages + // of the following formats: + // + // * Maven + // + // * Swift // - // * The namespace of a Maven package is its groupId. The namespace is required - // when requesting Maven packages. + // * generic // - // * The namespace of an npm package is its scope. + // * The namespace of a Maven package version is its groupId. // - // * Python and NuGet packages do not contain a corresponding component, - // packages of those formats do not have a namespace. + // * The namespace of an npm or Swift package version is its scope. // // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - // The name of the requested package. + // The package from which to get the associated package group. // // Package is a required field Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` - - // The name of the repository that contains the requested package. - // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -5929,7 +8685,7 @@ type DescribePackageInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribePackageInput) String() string { +func (s GetAssociatedPackageGroupInput) String() string { return awsutil.Prettify(s) } @@ -5938,13 +8694,13 @@ func (s DescribePackageInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribePackageInput) GoString() string { +func (s GetAssociatedPackageGroupInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DescribePackageInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribePackageInput"} +func (s *GetAssociatedPackageGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAssociatedPackageGroupInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -5966,12 +8722,6 @@ func (s *DescribePackageInput) Validate() error { if s.Package != nil && len(*s.Package) < 1 { invalidParams.Add(request.NewErrParamMinLen("Package", 1)) } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) - } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) - } if invalidParams.Len() > 0 { return invalidParams @@ -5980,49 +8730,45 @@ func (s *DescribePackageInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *DescribePackageInput) SetDomain(v string) *DescribePackageInput { +func (s *GetAssociatedPackageGroupInput) SetDomain(v string) *GetAssociatedPackageGroupInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *DescribePackageInput) SetDomainOwner(v string) *DescribePackageInput { +func (s *GetAssociatedPackageGroupInput) SetDomainOwner(v string) *GetAssociatedPackageGroupInput { s.DomainOwner = &v return s } // SetFormat sets the Format field's value. -func (s *DescribePackageInput) SetFormat(v string) *DescribePackageInput { +func (s *GetAssociatedPackageGroupInput) SetFormat(v string) *GetAssociatedPackageGroupInput { s.Format = &v return s } // SetNamespace sets the Namespace field's value. -func (s *DescribePackageInput) SetNamespace(v string) *DescribePackageInput { +func (s *GetAssociatedPackageGroupInput) SetNamespace(v string) *GetAssociatedPackageGroupInput { s.Namespace = &v return s } // SetPackage sets the Package field's value. -func (s *DescribePackageInput) SetPackage(v string) *DescribePackageInput { +func (s *GetAssociatedPackageGroupInput) SetPackage(v string) *GetAssociatedPackageGroupInput { s.Package = &v return s } -// SetRepository sets the Repository field's value. -func (s *DescribePackageInput) SetRepository(v string) *DescribePackageInput { - s.Repository = &v - return s -} - -type DescribePackageOutput struct { +type GetAssociatedPackageGroupOutput struct { _ struct{} `type:"structure"` - // A PackageDescription (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageDescription.html) - // object that contains information about the requested package. - // - // Package is a required field - Package *PackageDescription `locationName:"package" type:"structure" required:"true"` + // Describes the strength of the association between the package and package + // group. A strong match is also known as an exact match, and a weak match is + // known as a relative match. + AssociationType *string `locationName:"associationType" type:"string" enum:"PackageGroupAssociationType"` + + // The package group that is associated with the requested package. + PackageGroup *PackageGroupDescription `locationName:"packageGroup" type:"structure"` } // String returns the string representation. @@ -6030,7 +8776,7 @@ type DescribePackageOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribePackageOutput) String() string { +func (s GetAssociatedPackageGroupOutput) String() string { return awsutil.Prettify(s) } @@ -6039,21 +8785,26 @@ func (s DescribePackageOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribePackageOutput) GoString() string { +func (s GetAssociatedPackageGroupOutput) GoString() string { return s.String() } -// SetPackage sets the Package field's value. -func (s *DescribePackageOutput) SetPackage(v *PackageDescription) *DescribePackageOutput { - s.Package = v +// SetAssociationType sets the AssociationType field's value. +func (s *GetAssociatedPackageGroupOutput) SetAssociationType(v string) *GetAssociatedPackageGroupOutput { + s.AssociationType = &v return s } -type DescribePackageVersionInput struct { +// SetPackageGroup sets the PackageGroup field's value. +func (s *GetAssociatedPackageGroupOutput) SetPackageGroup(v *PackageGroupDescription) *GetAssociatedPackageGroupOutput { + s.PackageGroup = v + return s +} + +type GetAuthorizationTokenInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository that contains the package - // version. + // The name of the domain that is in scope for the generated authorization token. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -6062,38 +8813,11 @@ type DescribePackageVersionInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // A format that specifies the type of the requested package version. - // - // Format is a required field - Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - - // The namespace of the requested package version. The package version component - // that specifies its namespace depends on its type. For example: - // - // * The namespace of a Maven package version is its groupId. - // - // * The namespace of an npm package version is its scope. - // - // * Python and NuGet package versions do not contain a corresponding component, - // package versions of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. - Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - - // The name of the requested package version. - // - // Package is a required field - Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` - - // A string that contains the package version (for example, 3.5.2). - // - // PackageVersion is a required field - PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` - - // The name of the repository that contains the package version. - // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + // The time, in seconds, that the generated authorization token is valid. Valid + // values are 0 and any number between 900 (15 minutes) and 43200 (12 hours). + // A value of 0 will set the expiration of the authorization token to the same + // expiration of the user's role's temporary credentials. + DurationSeconds *int64 `location:"querystring" locationName:"duration" type:"long"` } // String returns the string representation. @@ -6101,7 +8825,7 @@ type DescribePackageVersionInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribePackageVersionInput) String() string { +func (s GetAuthorizationTokenInput) String() string { return awsutil.Prettify(s) } @@ -6110,13 +8834,13 @@ func (s DescribePackageVersionInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribePackageVersionInput) GoString() string { +func (s GetAuthorizationTokenInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DescribePackageVersionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribePackageVersionInput"} +func (s *GetAuthorizationTokenInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetAuthorizationTokenInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -6126,30 +8850,6 @@ func (s *DescribePackageVersionInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Format == nil { - invalidParams.Add(request.NewErrParamRequired("Format")) - } - if s.Namespace != nil && len(*s.Namespace) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) - } - if s.Package == nil { - invalidParams.Add(request.NewErrParamRequired("Package")) - } - if s.Package != nil && len(*s.Package) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Package", 1)) - } - if s.PackageVersion == nil { - invalidParams.Add(request.NewErrParamRequired("PackageVersion")) - } - if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) - } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) - } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) - } if invalidParams.Len() > 0 { return invalidParams @@ -6158,55 +8858,31 @@ func (s *DescribePackageVersionInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *DescribePackageVersionInput) SetDomain(v string) *DescribePackageVersionInput { +func (s *GetAuthorizationTokenInput) SetDomain(v string) *GetAuthorizationTokenInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *DescribePackageVersionInput) SetDomainOwner(v string) *DescribePackageVersionInput { +func (s *GetAuthorizationTokenInput) SetDomainOwner(v string) *GetAuthorizationTokenInput { s.DomainOwner = &v return s } -// SetFormat sets the Format field's value. -func (s *DescribePackageVersionInput) SetFormat(v string) *DescribePackageVersionInput { - s.Format = &v - return s -} - -// SetNamespace sets the Namespace field's value. -func (s *DescribePackageVersionInput) SetNamespace(v string) *DescribePackageVersionInput { - s.Namespace = &v - return s -} - -// SetPackage sets the Package field's value. -func (s *DescribePackageVersionInput) SetPackage(v string) *DescribePackageVersionInput { - s.Package = &v - return s -} - -// SetPackageVersion sets the PackageVersion field's value. -func (s *DescribePackageVersionInput) SetPackageVersion(v string) *DescribePackageVersionInput { - s.PackageVersion = &v +// SetDurationSeconds sets the DurationSeconds field's value. +func (s *GetAuthorizationTokenInput) SetDurationSeconds(v int64) *GetAuthorizationTokenInput { + s.DurationSeconds = &v return s } -// SetRepository sets the Repository field's value. -func (s *DescribePackageVersionInput) SetRepository(v string) *DescribePackageVersionInput { - s.Repository = &v - return s -} +type GetAuthorizationTokenOutput struct { + _ struct{} `type:"structure" sensitive:"true"` -type DescribePackageVersionOutput struct { - _ struct{} `type:"structure"` + // The returned authentication token. + AuthorizationToken *string `locationName:"authorizationToken" type:"string"` - // A PackageVersionDescription (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionDescription.html) - // object that contains information about the requested package version. - // - // PackageVersion is a required field - PackageVersion *PackageVersionDescription `locationName:"packageVersion" type:"structure" required:"true"` + // A timestamp that specifies the date and time the authorization token expires. + Expiration *time.Time `locationName:"expiration" type:"timestamp"` } // String returns the string representation. @@ -6214,7 +8890,7 @@ type DescribePackageVersionOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribePackageVersionOutput) String() string { +func (s GetAuthorizationTokenOutput) String() string { return awsutil.Prettify(s) } @@ -6223,20 +8899,26 @@ func (s DescribePackageVersionOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribePackageVersionOutput) GoString() string { +func (s GetAuthorizationTokenOutput) GoString() string { return s.String() } -// SetPackageVersion sets the PackageVersion field's value. -func (s *DescribePackageVersionOutput) SetPackageVersion(v *PackageVersionDescription) *DescribePackageVersionOutput { - s.PackageVersion = v +// SetAuthorizationToken sets the AuthorizationToken field's value. +func (s *GetAuthorizationTokenOutput) SetAuthorizationToken(v string) *GetAuthorizationTokenOutput { + s.AuthorizationToken = &v return s } -type DescribeRepositoryInput struct { +// SetExpiration sets the Expiration field's value. +func (s *GetAuthorizationTokenOutput) SetExpiration(v time.Time) *GetAuthorizationTokenOutput { + s.Expiration = &v + return s +} + +type GetDomainPermissionsPolicyInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository to describe. + // The name of the domain to which the resource policy is attached. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -6244,11 +8926,6 @@ type DescribeRepositoryInput struct { // The 12-digit account number of the Amazon Web Services account that owns // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - - // A string that specifies the name of the requested repository. - // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -6256,7 +8933,7 @@ type DescribeRepositoryInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribeRepositoryInput) String() string { +func (s GetDomainPermissionsPolicyInput) String() string { return awsutil.Prettify(s) } @@ -6265,13 +8942,13 @@ func (s DescribeRepositoryInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribeRepositoryInput) GoString() string { +func (s GetDomainPermissionsPolicyInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DescribeRepositoryInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DescribeRepositoryInput"} +func (s *GetDomainPermissionsPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetDomainPermissionsPolicyInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -6281,12 +8958,6 @@ func (s *DescribeRepositoryInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) - } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) - } if invalidParams.Len() > 0 { return invalidParams @@ -6295,28 +8966,22 @@ func (s *DescribeRepositoryInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *DescribeRepositoryInput) SetDomain(v string) *DescribeRepositoryInput { +func (s *GetDomainPermissionsPolicyInput) SetDomain(v string) *GetDomainPermissionsPolicyInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *DescribeRepositoryInput) SetDomainOwner(v string) *DescribeRepositoryInput { +func (s *GetDomainPermissionsPolicyInput) SetDomainOwner(v string) *GetDomainPermissionsPolicyInput { s.DomainOwner = &v return s } -// SetRepository sets the Repository field's value. -func (s *DescribeRepositoryInput) SetRepository(v string) *DescribeRepositoryInput { - s.Repository = &v - return s -} - -type DescribeRepositoryOutput struct { +type GetDomainPermissionsPolicyOutput struct { _ struct{} `type:"structure"` - // A RepositoryDescription object that contains the requested repository information. - Repository *RepositoryDescription `locationName:"repository" type:"structure"` + // The returned resource policy. + Policy *ResourcePolicy `locationName:"policy" type:"structure"` } // String returns the string representation. @@ -6324,7 +8989,7 @@ type DescribeRepositoryOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribeRepositoryOutput) String() string { +func (s GetDomainPermissionsPolicyOutput) String() string { return awsutil.Prettify(s) } @@ -6333,21 +8998,26 @@ func (s DescribeRepositoryOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DescribeRepositoryOutput) GoString() string { +func (s GetDomainPermissionsPolicyOutput) GoString() string { return s.String() } -// SetRepository sets the Repository field's value. -func (s *DescribeRepositoryOutput) SetRepository(v *RepositoryDescription) *DescribeRepositoryOutput { - s.Repository = v +// SetPolicy sets the Policy field's value. +func (s *GetDomainPermissionsPolicyOutput) SetPolicy(v *ResourcePolicy) *GetDomainPermissionsPolicyOutput { + s.Policy = v return s } -type DisassociateExternalConnectionInput struct { +type GetPackageVersionAssetInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository from which to remove - // the external repository. + // The name of the requested asset. + // + // Asset is a required field + Asset *string `location:"querystring" locationName:"asset" min:"1" type:"string" required:"true"` + + // The name of the domain that contains the repository that contains the package + // version with the requested asset. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -6356,12 +9026,48 @@ type DisassociateExternalConnectionInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The name of the external connection to be removed from the repository. + // A format that specifies the type of the package version with the requested + // asset file. // - // ExternalConnection is a required field - ExternalConnection *string `location:"querystring" locationName:"external-connection" min:"2" type:"string" required:"true"` + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - // The name of the repository from which the external connection will be removed. + // The namespace of the package version with the requested asset file. The package + // component that specifies its namespace depends on its type. For example: + // + // The namespace is required when requesting assets from package versions of + // the following formats: + // + // * Maven + // + // * Swift + // + // * generic + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` + + // The name of the package that contains the requested asset. + // + // Package is a required field + Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + + // A string that contains the package version (for example, 3.5.2). + // + // PackageVersion is a required field + PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` + + // The name of the package version revision that contains the requested asset. + PackageVersionRevision *string `location:"querystring" locationName:"revision" min:"1" type:"string"` + + // The repository that contains the package version with the requested asset. // // Repository is a required field Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` @@ -6372,7 +9078,7 @@ type DisassociateExternalConnectionInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisassociateExternalConnectionInput) String() string { +func (s GetPackageVersionAssetInput) String() string { return awsutil.Prettify(s) } @@ -6381,13 +9087,19 @@ func (s DisassociateExternalConnectionInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisassociateExternalConnectionInput) GoString() string { +func (s GetPackageVersionAssetInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DisassociateExternalConnectionInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DisassociateExternalConnectionInput"} +func (s *GetPackageVersionAssetInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetPackageVersionAssetInput"} + if s.Asset == nil { + invalidParams.Add(request.NewErrParamRequired("Asset")) + } + if s.Asset != nil && len(*s.Asset) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Asset", 1)) + } if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -6397,11 +9109,26 @@ func (s *DisassociateExternalConnectionInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.ExternalConnection == nil { - invalidParams.Add(request.NewErrParamRequired("ExternalConnection")) + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) } - if s.ExternalConnection != nil && len(*s.ExternalConnection) < 2 { - invalidParams.Add(request.NewErrParamMinLen("ExternalConnection", 2)) + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) + } + if s.Package == nil { + invalidParams.Add(request.NewErrParamRequired("Package")) + } + if s.Package != nil && len(*s.Package) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + } + if s.PackageVersion == nil { + invalidParams.Add(request.NewErrParamRequired("PackageVersion")) + } + if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) + } + if s.PackageVersionRevision != nil && len(*s.PackageVersionRevision) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PackageVersionRevision", 1)) } if s.Repository == nil { invalidParams.Add(request.NewErrParamRequired("Repository")) @@ -6410,41 +9137,80 @@ func (s *DisassociateExternalConnectionInput) Validate() error { invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) } - if invalidParams.Len() > 0 { - return invalidParams - } - return nil + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAsset sets the Asset field's value. +func (s *GetPackageVersionAssetInput) SetAsset(v string) *GetPackageVersionAssetInput { + s.Asset = &v + return s +} + +// SetDomain sets the Domain field's value. +func (s *GetPackageVersionAssetInput) SetDomain(v string) *GetPackageVersionAssetInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *GetPackageVersionAssetInput) SetDomainOwner(v string) *GetPackageVersionAssetInput { + s.DomainOwner = &v + return s +} + +// SetFormat sets the Format field's value. +func (s *GetPackageVersionAssetInput) SetFormat(v string) *GetPackageVersionAssetInput { + s.Format = &v + return s +} + +// SetNamespace sets the Namespace field's value. +func (s *GetPackageVersionAssetInput) SetNamespace(v string) *GetPackageVersionAssetInput { + s.Namespace = &v + return s } -// SetDomain sets the Domain field's value. -func (s *DisassociateExternalConnectionInput) SetDomain(v string) *DisassociateExternalConnectionInput { - s.Domain = &v +// SetPackage sets the Package field's value. +func (s *GetPackageVersionAssetInput) SetPackage(v string) *GetPackageVersionAssetInput { + s.Package = &v return s } -// SetDomainOwner sets the DomainOwner field's value. -func (s *DisassociateExternalConnectionInput) SetDomainOwner(v string) *DisassociateExternalConnectionInput { - s.DomainOwner = &v +// SetPackageVersion sets the PackageVersion field's value. +func (s *GetPackageVersionAssetInput) SetPackageVersion(v string) *GetPackageVersionAssetInput { + s.PackageVersion = &v return s } -// SetExternalConnection sets the ExternalConnection field's value. -func (s *DisassociateExternalConnectionInput) SetExternalConnection(v string) *DisassociateExternalConnectionInput { - s.ExternalConnection = &v +// SetPackageVersionRevision sets the PackageVersionRevision field's value. +func (s *GetPackageVersionAssetInput) SetPackageVersionRevision(v string) *GetPackageVersionAssetInput { + s.PackageVersionRevision = &v return s } // SetRepository sets the Repository field's value. -func (s *DisassociateExternalConnectionInput) SetRepository(v string) *DisassociateExternalConnectionInput { +func (s *GetPackageVersionAssetInput) SetRepository(v string) *GetPackageVersionAssetInput { s.Repository = &v return s } -type DisassociateExternalConnectionOutput struct { - _ struct{} `type:"structure"` +type GetPackageVersionAssetOutput struct { + _ struct{} `type:"structure" payload:"Asset"` - // The repository associated with the removed external connection. - Repository *RepositoryDescription `locationName:"repository" type:"structure"` + // The binary file, or asset, that is downloaded. + Asset io.ReadCloser `locationName:"asset" type:"blob"` + + // The name of the asset that is downloaded. + AssetName *string `location:"header" locationName:"X-AssetName" min:"1" type:"string"` + + // A string that contains the package version (for example, 3.5.2). + PackageVersion *string `location:"header" locationName:"X-PackageVersion" min:"1" type:"string"` + + // The name of the package version revision that contains the downloaded asset. + PackageVersionRevision *string `location:"header" locationName:"X-PackageVersionRevision" min:"1" type:"string"` } // String returns the string representation. @@ -6452,7 +9218,7 @@ type DisassociateExternalConnectionOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisassociateExternalConnectionOutput) String() string { +func (s GetPackageVersionAssetOutput) String() string { return awsutil.Prettify(s) } @@ -6461,20 +9227,39 @@ func (s DisassociateExternalConnectionOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisassociateExternalConnectionOutput) GoString() string { +func (s GetPackageVersionAssetOutput) GoString() string { return s.String() } -// SetRepository sets the Repository field's value. -func (s *DisassociateExternalConnectionOutput) SetRepository(v *RepositoryDescription) *DisassociateExternalConnectionOutput { - s.Repository = v +// SetAsset sets the Asset field's value. +func (s *GetPackageVersionAssetOutput) SetAsset(v io.ReadCloser) *GetPackageVersionAssetOutput { + s.Asset = v return s } -type DisposePackageVersionsInput struct { - _ struct{} `type:"structure"` +// SetAssetName sets the AssetName field's value. +func (s *GetPackageVersionAssetOutput) SetAssetName(v string) *GetPackageVersionAssetOutput { + s.AssetName = &v + return s +} - // The name of the domain that contains the repository you want to dispose. +// SetPackageVersion sets the PackageVersion field's value. +func (s *GetPackageVersionAssetOutput) SetPackageVersion(v string) *GetPackageVersionAssetOutput { + s.PackageVersion = &v + return s +} + +// SetPackageVersionRevision sets the PackageVersionRevision field's value. +func (s *GetPackageVersionAssetOutput) SetPackageVersionRevision(v string) *GetPackageVersionAssetOutput { + s.PackageVersionRevision = &v + return s +} + +type GetPackageVersionReadmeInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The name of the domain that contains the repository that contains the package + // version with the requested readme file. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -6483,45 +9268,48 @@ type DisposePackageVersionsInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The expected status of the package version to dispose. - ExpectedStatus *string `locationName:"expectedStatus" type:"string" enum:"PackageVersionStatus"` - - // A format that specifies the type of package versions you want to dispose. + // A format that specifies the type of the package version with the requested + // readme file. // // Format is a required field Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - // The namespace of the package versions to be disposed. The package version - // component that specifies its namespace depends on its type. For example: + // The namespace of the package version with the requested readme file. The + // package component that specifies its namespace depends on its type. For example: + // + // The namespace is required when requesting the readme from package versions + // of the following formats: + // + // * Maven + // + // * Swift + // + // * generic // // * The namespace of a Maven package version is its groupId. // - // * The namespace of an npm package version is its scope. + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. // // * Python and NuGet package versions do not contain a corresponding component, // package versions of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - // The name of the package with the versions you want to dispose. + // The name of the package version that contains the requested readme file. // // Package is a required field Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` - // The name of the repository that contains the package versions you want to - // dispose. + // A string that contains the package version (for example, 3.5.2). // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` - - // The revisions of the package versions you want to dispose. - VersionRevisions map[string]*string `locationName:"versionRevisions" type:"map"` + // PackageVersion is a required field + PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` - // The versions of the package you want to dispose. + // The repository that contains the package with the requested readme file. // - // Versions is a required field - Versions []*string `locationName:"versions" type:"list" required:"true"` + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -6529,7 +9317,7 @@ type DisposePackageVersionsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisposePackageVersionsInput) String() string { +func (s GetPackageVersionReadmeInput) String() string { return awsutil.Prettify(s) } @@ -6538,13 +9326,13 @@ func (s DisposePackageVersionsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DisposePackageVersionsInput) GoString() string { +func (s GetPackageVersionReadmeInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *DisposePackageVersionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "DisposePackageVersionsInput"} +func (s *GetPackageVersionReadmeInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetPackageVersionReadmeInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -6566,15 +9354,18 @@ func (s *DisposePackageVersionsInput) Validate() error { if s.Package != nil && len(*s.Package) < 1 { invalidParams.Add(request.NewErrParamMinLen("Package", 1)) } + if s.PackageVersion == nil { + invalidParams.Add(request.NewErrParamRequired("PackageVersion")) + } + if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) + } if s.Repository == nil { invalidParams.Add(request.NewErrParamRequired("Repository")) } if s.Repository != nil && len(*s.Repository) < 2 { invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) } - if s.Versions == nil { - invalidParams.Add(request.NewErrParamRequired("Versions")) - } if invalidParams.Len() > 0 { return invalidParams @@ -6583,144 +9374,77 @@ func (s *DisposePackageVersionsInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *DisposePackageVersionsInput) SetDomain(v string) *DisposePackageVersionsInput { +func (s *GetPackageVersionReadmeInput) SetDomain(v string) *GetPackageVersionReadmeInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *DisposePackageVersionsInput) SetDomainOwner(v string) *DisposePackageVersionsInput { +func (s *GetPackageVersionReadmeInput) SetDomainOwner(v string) *GetPackageVersionReadmeInput { s.DomainOwner = &v return s } -// SetExpectedStatus sets the ExpectedStatus field's value. -func (s *DisposePackageVersionsInput) SetExpectedStatus(v string) *DisposePackageVersionsInput { - s.ExpectedStatus = &v - return s -} - // SetFormat sets the Format field's value. -func (s *DisposePackageVersionsInput) SetFormat(v string) *DisposePackageVersionsInput { +func (s *GetPackageVersionReadmeInput) SetFormat(v string) *GetPackageVersionReadmeInput { s.Format = &v return s } // SetNamespace sets the Namespace field's value. -func (s *DisposePackageVersionsInput) SetNamespace(v string) *DisposePackageVersionsInput { +func (s *GetPackageVersionReadmeInput) SetNamespace(v string) *GetPackageVersionReadmeInput { s.Namespace = &v return s } // SetPackage sets the Package field's value. -func (s *DisposePackageVersionsInput) SetPackage(v string) *DisposePackageVersionsInput { +func (s *GetPackageVersionReadmeInput) SetPackage(v string) *GetPackageVersionReadmeInput { s.Package = &v return s } -// SetRepository sets the Repository field's value. -func (s *DisposePackageVersionsInput) SetRepository(v string) *DisposePackageVersionsInput { - s.Repository = &v - return s -} - -// SetVersionRevisions sets the VersionRevisions field's value. -func (s *DisposePackageVersionsInput) SetVersionRevisions(v map[string]*string) *DisposePackageVersionsInput { - s.VersionRevisions = v +// SetPackageVersion sets the PackageVersion field's value. +func (s *GetPackageVersionReadmeInput) SetPackageVersion(v string) *GetPackageVersionReadmeInput { + s.PackageVersion = &v return s } -// SetVersions sets the Versions field's value. -func (s *DisposePackageVersionsInput) SetVersions(v []*string) *DisposePackageVersionsInput { - s.Versions = v +// SetRepository sets the Repository field's value. +func (s *GetPackageVersionReadmeInput) SetRepository(v string) *GetPackageVersionReadmeInput { + s.Repository = &v return s } -type DisposePackageVersionsOutput struct { +type GetPackageVersionReadmeOutput struct { _ struct{} `type:"structure"` - // A PackageVersionError object that contains a map of errors codes for the - // disposed package versions that failed. The possible error codes are: - // - // * ALREADY_EXISTS - // - // * MISMATCHED_REVISION + // The format of the package with the requested readme file. + Format *string `locationName:"format" type:"string" enum:"PackageFormat"` + + // The namespace of the package version with the requested readme file. The + // package component that specifies its namespace depends on its type. For example: // - // * MISMATCHED_STATUS + // * The namespace of a Maven package version is its groupId. // - // * NOT_ALLOWED + // * The namespace of an npm or Swift package version is its scope. // - // * NOT_FOUND + // * The namespace of a generic package is its namespace. // - // * SKIPPED - FailedVersions map[string]*PackageVersionError `locationName:"failedVersions" type:"map"` - - // A list of the package versions that were successfully disposed. - SuccessfulVersions map[string]*SuccessfulPackageVersionInfo `locationName:"successfulVersions" type:"map"` -} - -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s DisposePackageVersionsOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s DisposePackageVersionsOutput) GoString() string { - return s.String() -} - -// SetFailedVersions sets the FailedVersions field's value. -func (s *DisposePackageVersionsOutput) SetFailedVersions(v map[string]*PackageVersionError) *DisposePackageVersionsOutput { - s.FailedVersions = v - return s -} - -// SetSuccessfulVersions sets the SuccessfulVersions field's value. -func (s *DisposePackageVersionsOutput) SetSuccessfulVersions(v map[string]*SuccessfulPackageVersionInfo) *DisposePackageVersionsOutput { - s.SuccessfulVersions = v - return s -} - -// Information about a domain. A domain is a container for repositories. When -// you create a domain, it is empty until you add one or more repositories. -type DomainDescription struct { - _ struct{} `type:"structure"` - - // The Amazon Resource Name (ARN) of the domain. - Arn *string `locationName:"arn" min:"1" type:"string"` - - // The total size of all assets in the domain. - AssetSizeBytes *int64 `locationName:"assetSizeBytes" type:"long"` - - // A timestamp that represents the date and time the domain was created. - CreatedTime *time.Time `locationName:"createdTime" type:"timestamp"` - - // The ARN of an Key Management Service (KMS) key associated with a domain. - EncryptionKey *string `locationName:"encryptionKey" min:"1" type:"string"` - - // The name of the domain. - Name *string `locationName:"name" min:"2" type:"string"` + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `locationName:"namespace" min:"1" type:"string"` - // The Amazon Web Services account ID that owns the domain. - Owner *string `locationName:"owner" min:"12" type:"string"` + // The name of the package that contains the returned readme file. + Package *string `locationName:"package" min:"1" type:"string"` - // The number of repositories in the domain. - RepositoryCount *int64 `locationName:"repositoryCount" type:"integer"` + // The text of the returned readme file. + Readme *string `locationName:"readme" type:"string"` - // The Amazon Resource Name (ARN) of the Amazon S3 bucket that is used to store - // package assets in the domain. - S3BucketArn *string `locationName:"s3BucketArn" min:"1" type:"string"` + // The version of the package with the requested readme file. + Version *string `locationName:"version" min:"1" type:"string"` - // The current status of a domain. - Status *string `locationName:"status" type:"string" enum:"DomainStatus"` + // The current revision associated with the package version. + VersionRevision *string `locationName:"versionRevision" min:"1" type:"string"` } // String returns the string representation. @@ -6728,7 +9452,7 @@ type DomainDescription struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DomainDescription) String() string { +func (s GetPackageVersionReadmeOutput) String() string { return awsutil.Prettify(s) } @@ -6737,78 +9461,68 @@ func (s DomainDescription) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DomainDescription) GoString() string { +func (s GetPackageVersionReadmeOutput) GoString() string { return s.String() } -// SetArn sets the Arn field's value. -func (s *DomainDescription) SetArn(v string) *DomainDescription { - s.Arn = &v - return s -} - -// SetAssetSizeBytes sets the AssetSizeBytes field's value. -func (s *DomainDescription) SetAssetSizeBytes(v int64) *DomainDescription { - s.AssetSizeBytes = &v +// SetFormat sets the Format field's value. +func (s *GetPackageVersionReadmeOutput) SetFormat(v string) *GetPackageVersionReadmeOutput { + s.Format = &v return s } -// SetCreatedTime sets the CreatedTime field's value. -func (s *DomainDescription) SetCreatedTime(v time.Time) *DomainDescription { - s.CreatedTime = &v +// SetNamespace sets the Namespace field's value. +func (s *GetPackageVersionReadmeOutput) SetNamespace(v string) *GetPackageVersionReadmeOutput { + s.Namespace = &v return s } -// SetEncryptionKey sets the EncryptionKey field's value. -func (s *DomainDescription) SetEncryptionKey(v string) *DomainDescription { - s.EncryptionKey = &v +// SetPackage sets the Package field's value. +func (s *GetPackageVersionReadmeOutput) SetPackage(v string) *GetPackageVersionReadmeOutput { + s.Package = &v return s } -// SetName sets the Name field's value. -func (s *DomainDescription) SetName(v string) *DomainDescription { - s.Name = &v +// SetReadme sets the Readme field's value. +func (s *GetPackageVersionReadmeOutput) SetReadme(v string) *GetPackageVersionReadmeOutput { + s.Readme = &v return s } -// SetOwner sets the Owner field's value. -func (s *DomainDescription) SetOwner(v string) *DomainDescription { - s.Owner = &v +// SetVersion sets the Version field's value. +func (s *GetPackageVersionReadmeOutput) SetVersion(v string) *GetPackageVersionReadmeOutput { + s.Version = &v return s } -// SetRepositoryCount sets the RepositoryCount field's value. -func (s *DomainDescription) SetRepositoryCount(v int64) *DomainDescription { - s.RepositoryCount = &v +// SetVersionRevision sets the VersionRevision field's value. +func (s *GetPackageVersionReadmeOutput) SetVersionRevision(v string) *GetPackageVersionReadmeOutput { + s.VersionRevision = &v return s } -// SetS3BucketArn sets the S3BucketArn field's value. -func (s *DomainDescription) SetS3BucketArn(v string) *DomainDescription { - s.S3BucketArn = &v - return s -} +type GetRepositoryEndpointInput struct { + _ struct{} `type:"structure" nopayload:"true"` -// SetStatus sets the Status field's value. -func (s *DomainDescription) SetStatus(v string) *DomainDescription { - s.Status = &v - return s -} + // The name of the domain that contains the repository. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` -// Information about how a package originally entered the CodeArtifact domain. -// For packages published directly to CodeArtifact, the entry point is the repository -// it was published to. For packages ingested from an external repository, the -// entry point is the external connection that it was ingested from. An external -// connection is a CodeArtifact repository that is connected to an external -// repository such as the npm registry or NuGet gallery. -type DomainEntryPoint struct { - _ struct{} `type:"structure"` + // The 12-digit account number of the Amazon Web Services account that owns + // the domain that contains the repository. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The name of the external connection that a package was ingested from. - ExternalConnectionName *string `locationName:"externalConnectionName" min:"2" type:"string"` + // Returns which endpoint of a repository to return. A repository has one endpoint + // for each package format. + // + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - // The name of the repository that a package was originally published to. - RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"` + // The name of the repository. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -6816,7 +9530,7 @@ type DomainEntryPoint struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DomainEntryPoint) String() string { +func (s GetRepositoryEndpointInput) String() string { return awsutil.Prettify(s) } @@ -6825,46 +9539,67 @@ func (s DomainEntryPoint) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DomainEntryPoint) GoString() string { +func (s GetRepositoryEndpointInput) GoString() string { return s.String() } -// SetExternalConnectionName sets the ExternalConnectionName field's value. -func (s *DomainEntryPoint) SetExternalConnectionName(v string) *DomainEntryPoint { - s.ExternalConnectionName = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *GetRepositoryEndpointInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetRepositoryEndpointInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) + } + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetRepositoryName sets the RepositoryName field's value. -func (s *DomainEntryPoint) SetRepositoryName(v string) *DomainEntryPoint { - s.RepositoryName = &v +// SetDomain sets the Domain field's value. +func (s *GetRepositoryEndpointInput) SetDomain(v string) *GetRepositoryEndpointInput { + s.Domain = &v return s } -// Information about a domain, including its name, Amazon Resource Name (ARN), -// and status. The ListDomains (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_ListDomains.html) -// operation returns a list of DomainSummary objects. -type DomainSummary struct { - _ struct{} `type:"structure"` - - // The ARN of the domain. - Arn *string `locationName:"arn" min:"1" type:"string"` - - // A timestamp that contains the date and time the domain was created. - CreatedTime *time.Time `locationName:"createdTime" type:"timestamp"` +// SetDomainOwner sets the DomainOwner field's value. +func (s *GetRepositoryEndpointInput) SetDomainOwner(v string) *GetRepositoryEndpointInput { + s.DomainOwner = &v + return s +} - // The key used to encrypt the domain. - EncryptionKey *string `locationName:"encryptionKey" min:"1" type:"string"` +// SetFormat sets the Format field's value. +func (s *GetRepositoryEndpointInput) SetFormat(v string) *GetRepositoryEndpointInput { + s.Format = &v + return s +} - // The name of the domain. - Name *string `locationName:"name" min:"2" type:"string"` +// SetRepository sets the Repository field's value. +func (s *GetRepositoryEndpointInput) SetRepository(v string) *GetRepositoryEndpointInput { + s.Repository = &v + return s +} - // The 12-digit account number of the Amazon Web Services account that owns - // the domain. It does not include dashes or spaces. - Owner *string `locationName:"owner" min:"12" type:"string"` +type GetRepositoryEndpointOutput struct { + _ struct{} `type:"structure"` - // A string that contains the status of the domain. - Status *string `locationName:"status" type:"string" enum:"DomainStatus"` + // A string that specifies the URL of the returned endpoint. + RepositoryEndpoint *string `locationName:"repositoryEndpoint" type:"string"` } // String returns the string representation. @@ -6872,7 +9607,7 @@ type DomainSummary struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DomainSummary) String() string { +func (s GetRepositoryEndpointOutput) String() string { return awsutil.Prettify(s) } @@ -6881,50 +9616,21 @@ func (s DomainSummary) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s DomainSummary) GoString() string { +func (s GetRepositoryEndpointOutput) GoString() string { return s.String() } -// SetArn sets the Arn field's value. -func (s *DomainSummary) SetArn(v string) *DomainSummary { - s.Arn = &v - return s -} - -// SetCreatedTime sets the CreatedTime field's value. -func (s *DomainSummary) SetCreatedTime(v time.Time) *DomainSummary { - s.CreatedTime = &v - return s -} - -// SetEncryptionKey sets the EncryptionKey field's value. -func (s *DomainSummary) SetEncryptionKey(v string) *DomainSummary { - s.EncryptionKey = &v - return s -} - -// SetName sets the Name field's value. -func (s *DomainSummary) SetName(v string) *DomainSummary { - s.Name = &v - return s -} - -// SetOwner sets the Owner field's value. -func (s *DomainSummary) SetOwner(v string) *DomainSummary { - s.Owner = &v - return s -} - -// SetStatus sets the Status field's value. -func (s *DomainSummary) SetStatus(v string) *DomainSummary { - s.Status = &v +// SetRepositoryEndpoint sets the RepositoryEndpoint field's value. +func (s *GetRepositoryEndpointOutput) SetRepositoryEndpoint(v string) *GetRepositoryEndpointOutput { + s.RepositoryEndpoint = &v return s } -type GetAuthorizationTokenInput struct { +type GetRepositoryPermissionsPolicyInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that is in scope for the generated authorization token. + // The name of the domain containing the repository whose associated resource + // policy is to be retrieved. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -6933,11 +9639,10 @@ type GetAuthorizationTokenInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The time, in seconds, that the generated authorization token is valid. Valid - // values are 0 and any number between 900 (15 minutes) and 43200 (12 hours). - // A value of 0 will set the expiration of the authorization token to the same - // expiration of the user's role's temporary credentials. - DurationSeconds *int64 `location:"querystring" locationName:"duration" type:"long"` + // The name of the repository whose associated resource policy is to be retrieved. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -6945,7 +9650,7 @@ type GetAuthorizationTokenInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAuthorizationTokenInput) String() string { +func (s GetRepositoryPermissionsPolicyInput) String() string { return awsutil.Prettify(s) } @@ -6954,13 +9659,13 @@ func (s GetAuthorizationTokenInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAuthorizationTokenInput) GoString() string { +func (s GetRepositoryPermissionsPolicyInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetAuthorizationTokenInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetAuthorizationTokenInput"} +func (s *GetRepositoryPermissionsPolicyInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "GetRepositoryPermissionsPolicyInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -6970,6 +9675,12 @@ func (s *GetAuthorizationTokenInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + } if invalidParams.Len() > 0 { return invalidParams @@ -6978,31 +9689,28 @@ func (s *GetAuthorizationTokenInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *GetAuthorizationTokenInput) SetDomain(v string) *GetAuthorizationTokenInput { +func (s *GetRepositoryPermissionsPolicyInput) SetDomain(v string) *GetRepositoryPermissionsPolicyInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *GetAuthorizationTokenInput) SetDomainOwner(v string) *GetAuthorizationTokenInput { +func (s *GetRepositoryPermissionsPolicyInput) SetDomainOwner(v string) *GetRepositoryPermissionsPolicyInput { s.DomainOwner = &v return s } -// SetDurationSeconds sets the DurationSeconds field's value. -func (s *GetAuthorizationTokenInput) SetDurationSeconds(v int64) *GetAuthorizationTokenInput { - s.DurationSeconds = &v +// SetRepository sets the Repository field's value. +func (s *GetRepositoryPermissionsPolicyInput) SetRepository(v string) *GetRepositoryPermissionsPolicyInput { + s.Repository = &v return s } -type GetAuthorizationTokenOutput struct { +type GetRepositoryPermissionsPolicyOutput struct { _ struct{} `type:"structure"` - // The returned authentication token. - AuthorizationToken *string `locationName:"authorizationToken" type:"string"` - - // A timestamp that specifies the date and time the authorization token expires. - Expiration *time.Time `locationName:"expiration" type:"timestamp"` + // The returned resource policy. + Policy *ResourcePolicy `locationName:"policy" type:"structure"` } // String returns the string representation. @@ -7010,7 +9718,7 @@ type GetAuthorizationTokenOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAuthorizationTokenOutput) String() string { +func (s GetRepositoryPermissionsPolicyOutput) String() string { return awsutil.Prettify(s) } @@ -7019,33 +9727,22 @@ func (s GetAuthorizationTokenOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetAuthorizationTokenOutput) GoString() string { +func (s GetRepositoryPermissionsPolicyOutput) GoString() string { return s.String() } -// SetAuthorizationToken sets the AuthorizationToken field's value. -func (s *GetAuthorizationTokenOutput) SetAuthorizationToken(v string) *GetAuthorizationTokenOutput { - s.AuthorizationToken = &v - return s -} - -// SetExpiration sets the Expiration field's value. -func (s *GetAuthorizationTokenOutput) SetExpiration(v time.Time) *GetAuthorizationTokenOutput { - s.Expiration = &v +// SetPolicy sets the Policy field's value. +func (s *GetRepositoryPermissionsPolicyOutput) SetPolicy(v *ResourcePolicy) *GetRepositoryPermissionsPolicyOutput { + s.Policy = v return s } -type GetDomainPermissionsPolicyInput struct { - _ struct{} `type:"structure" nopayload:"true"` - - // The name of the domain to which the resource policy is attached. - // - // Domain is a required field - Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` +// The operation did not succeed because of an error that occurred inside CodeArtifact. +type InternalServerException struct { + _ struct{} `type:"structure"` + RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - // The 12-digit account number of the Amazon Web Services account that owns - // the domain. It does not include dashes or spaces. - DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + Message_ *string `locationName:"message" type:"string"` } // String returns the string representation. @@ -7053,7 +9750,7 @@ type GetDomainPermissionsPolicyInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetDomainPermissionsPolicyInput) String() string { +func (s InternalServerException) String() string { return awsutil.Prettify(s) } @@ -7062,46 +9759,57 @@ func (s GetDomainPermissionsPolicyInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetDomainPermissionsPolicyInput) GoString() string { +func (s InternalServerException) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *GetDomainPermissionsPolicyInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetDomainPermissionsPolicyInput"} - if s.Domain == nil { - invalidParams.Add(request.NewErrParamRequired("Domain")) - } - if s.Domain != nil && len(*s.Domain) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) - } - if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { - invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) +func newErrorInternalServerException(v protocol.ResponseMetadata) error { + return &InternalServerException{ + RespMetadata: v, } +} - if invalidParams.Len() > 0 { - return invalidParams +// Code returns the exception type name. +func (s *InternalServerException) Code() string { + return "InternalServerException" +} + +// Message returns the exception's message. +func (s *InternalServerException) Message() string { + if s.Message_ != nil { + return *s.Message_ } + return "" +} + +// OrigErr always returns nil, satisfies awserr.Error interface. +func (s *InternalServerException) OrigErr() error { return nil } -// SetDomain sets the Domain field's value. -func (s *GetDomainPermissionsPolicyInput) SetDomain(v string) *GetDomainPermissionsPolicyInput { - s.Domain = &v - return s +func (s *InternalServerException) Error() string { + return fmt.Sprintf("%s: %s", s.Code(), s.Message()) } -// SetDomainOwner sets the DomainOwner field's value. -func (s *GetDomainPermissionsPolicyInput) SetDomainOwner(v string) *GetDomainPermissionsPolicyInput { - s.DomainOwner = &v - return s +// Status code returns the HTTP status code for the request's response error. +func (s *InternalServerException) StatusCode() int { + return s.RespMetadata.StatusCode } -type GetDomainPermissionsPolicyOutput struct { +// RequestID returns the service's response RequestID for request. +func (s *InternalServerException) RequestID() string { + return s.RespMetadata.RequestID +} + +// Details of the license data. +type LicenseInfo struct { _ struct{} `type:"structure"` - // The returned resource policy. - Policy *ResourcePolicy `locationName:"policy" type:"structure"` + // Name of the license. + Name *string `locationName:"name" type:"string"` + + // The URL for license data. + Url *string `locationName:"url" type:"string"` } // String returns the string representation. @@ -7109,7 +9817,7 @@ type GetDomainPermissionsPolicyOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetDomainPermissionsPolicyOutput) String() string { +func (s LicenseInfo) String() string { return awsutil.Prettify(s) } @@ -7118,26 +9826,27 @@ func (s GetDomainPermissionsPolicyOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetDomainPermissionsPolicyOutput) GoString() string { +func (s LicenseInfo) GoString() string { return s.String() } -// SetPolicy sets the Policy field's value. -func (s *GetDomainPermissionsPolicyOutput) SetPolicy(v *ResourcePolicy) *GetDomainPermissionsPolicyOutput { - s.Policy = v +// SetName sets the Name field's value. +func (s *LicenseInfo) SetName(v string) *LicenseInfo { + s.Name = &v return s } -type GetPackageVersionAssetInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// SetUrl sets the Url field's value. +func (s *LicenseInfo) SetUrl(v string) *LicenseInfo { + s.Url = &v + return s +} - // The name of the requested asset. - // - // Asset is a required field - Asset *string `location:"querystring" locationName:"asset" min:"1" type:"string" required:"true"` +type ListAllowedRepositoriesForGroupInput struct { + _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository that contains the package - // version with the requested asset. + // The name of the domain that contains the package group from which to list + // allowed repositories. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -7146,42 +9855,22 @@ type GetPackageVersionAssetInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // A format that specifies the type of the package version with the requested - // asset file. - // - // Format is a required field - Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - - // The namespace of the package version with the requested asset file. The package - // version component that specifies its namespace depends on its type. For example: - // - // * The namespace of a Maven package version is its groupId. - // - // * The namespace of an npm package version is its scope. - // - // * Python and NuGet package versions do not contain a corresponding component, - // package versions of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. - Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` + // The maximum number of results to return per page. + MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` - // The name of the package that contains the requested asset. - // - // Package is a required field - Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` - // A string that contains the package version (for example, 3.5.2). + // The origin configuration restriction type of which to list allowed repositories. // - // PackageVersion is a required field - PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` + // OriginRestrictionType is a required field + OriginRestrictionType *string `location:"querystring" locationName:"originRestrictionType" type:"string" required:"true" enum:"PackageGroupOriginRestrictionType"` - // The name of the package version revision that contains the requested asset. - PackageVersionRevision *string `location:"querystring" locationName:"revision" min:"1" type:"string"` - - // The repository that contains the package version with the requested asset. + // The pattern of the package group from which to list allowed repositories. // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + // PackageGroup is a required field + PackageGroup *string `location:"querystring" locationName:"package-group" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -7189,7 +9878,7 @@ type GetPackageVersionAssetInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetPackageVersionAssetInput) String() string { +func (s ListAllowedRepositoriesForGroupInput) String() string { return awsutil.Prettify(s) } @@ -7198,19 +9887,13 @@ func (s GetPackageVersionAssetInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetPackageVersionAssetInput) GoString() string { +func (s ListAllowedRepositoriesForGroupInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetPackageVersionAssetInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetPackageVersionAssetInput"} - if s.Asset == nil { - invalidParams.Add(request.NewErrParamRequired("Asset")) - } - if s.Asset != nil && len(*s.Asset) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Asset", 1)) - } +func (s *ListAllowedRepositoriesForGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAllowedRepositoriesForGroupInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -7220,32 +9903,20 @@ func (s *GetPackageVersionAssetInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Format == nil { - invalidParams.Add(request.NewErrParamRequired("Format")) - } - if s.Namespace != nil && len(*s.Namespace) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) - } - if s.Package == nil { - invalidParams.Add(request.NewErrParamRequired("Package")) - } - if s.Package != nil && len(*s.Package) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Package", 1)) - } - if s.PackageVersion == nil { - invalidParams.Add(request.NewErrParamRequired("PackageVersion")) + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } - if s.PackageVersionRevision != nil && len(*s.PackageVersionRevision) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PackageVersionRevision", 1)) + if s.OriginRestrictionType == nil { + invalidParams.Add(request.NewErrParamRequired("OriginRestrictionType")) } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) + if s.PackageGroup == nil { + invalidParams.Add(request.NewErrParamRequired("PackageGroup")) } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + if s.PackageGroup != nil && len(*s.PackageGroup) < 2 { + invalidParams.Add(request.NewErrParamMinLen("PackageGroup", 2)) } if invalidParams.Len() > 0 { @@ -7254,74 +9925,52 @@ func (s *GetPackageVersionAssetInput) Validate() error { return nil } -// SetAsset sets the Asset field's value. -func (s *GetPackageVersionAssetInput) SetAsset(v string) *GetPackageVersionAssetInput { - s.Asset = &v - return s -} - // SetDomain sets the Domain field's value. -func (s *GetPackageVersionAssetInput) SetDomain(v string) *GetPackageVersionAssetInput { +func (s *ListAllowedRepositoriesForGroupInput) SetDomain(v string) *ListAllowedRepositoriesForGroupInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *GetPackageVersionAssetInput) SetDomainOwner(v string) *GetPackageVersionAssetInput { +func (s *ListAllowedRepositoriesForGroupInput) SetDomainOwner(v string) *ListAllowedRepositoriesForGroupInput { s.DomainOwner = &v return s } -// SetFormat sets the Format field's value. -func (s *GetPackageVersionAssetInput) SetFormat(v string) *GetPackageVersionAssetInput { - s.Format = &v - return s -} - -// SetNamespace sets the Namespace field's value. -func (s *GetPackageVersionAssetInput) SetNamespace(v string) *GetPackageVersionAssetInput { - s.Namespace = &v - return s -} - -// SetPackage sets the Package field's value. -func (s *GetPackageVersionAssetInput) SetPackage(v string) *GetPackageVersionAssetInput { - s.Package = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListAllowedRepositoriesForGroupInput) SetMaxResults(v int64) *ListAllowedRepositoriesForGroupInput { + s.MaxResults = &v return s } -// SetPackageVersion sets the PackageVersion field's value. -func (s *GetPackageVersionAssetInput) SetPackageVersion(v string) *GetPackageVersionAssetInput { - s.PackageVersion = &v +// SetNextToken sets the NextToken field's value. +func (s *ListAllowedRepositoriesForGroupInput) SetNextToken(v string) *ListAllowedRepositoriesForGroupInput { + s.NextToken = &v return s } -// SetPackageVersionRevision sets the PackageVersionRevision field's value. -func (s *GetPackageVersionAssetInput) SetPackageVersionRevision(v string) *GetPackageVersionAssetInput { - s.PackageVersionRevision = &v +// SetOriginRestrictionType sets the OriginRestrictionType field's value. +func (s *ListAllowedRepositoriesForGroupInput) SetOriginRestrictionType(v string) *ListAllowedRepositoriesForGroupInput { + s.OriginRestrictionType = &v return s } -// SetRepository sets the Repository field's value. -func (s *GetPackageVersionAssetInput) SetRepository(v string) *GetPackageVersionAssetInput { - s.Repository = &v +// SetPackageGroup sets the PackageGroup field's value. +func (s *ListAllowedRepositoriesForGroupInput) SetPackageGroup(v string) *ListAllowedRepositoriesForGroupInput { + s.PackageGroup = &v return s } -type GetPackageVersionAssetOutput struct { - _ struct{} `type:"structure" payload:"Asset"` - - // The binary file, or asset, that is downloaded. - Asset io.ReadCloser `locationName:"asset" type:"blob"` - - // The name of the asset that is downloaded. - AssetName *string `location:"header" locationName:"X-AssetName" min:"1" type:"string"` +type ListAllowedRepositoriesForGroupOutput struct { + _ struct{} `type:"structure"` - // A string that contains the package version (for example, 3.5.2). - PackageVersion *string `location:"header" locationName:"X-PackageVersion" min:"1" type:"string"` + // The list of allowed repositories for the package group and origin configuration + // restriction type. + AllowedRepositories []*string `locationName:"allowedRepositories" type:"list"` - // The name of the package version revision that contains the downloaded asset. - PackageVersionRevision *string `location:"header" locationName:"X-PackageVersionRevision" min:"1" type:"string"` + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7329,48 +9978,36 @@ type GetPackageVersionAssetOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetPackageVersionAssetOutput) String() string { +func (s ListAllowedRepositoriesForGroupOutput) String() string { return awsutil.Prettify(s) } // GoString returns the string representation. // -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GetPackageVersionAssetOutput) GoString() string { - return s.String() -} - -// SetAsset sets the Asset field's value. -func (s *GetPackageVersionAssetOutput) SetAsset(v io.ReadCloser) *GetPackageVersionAssetOutput { - s.Asset = v - return s -} - -// SetAssetName sets the AssetName field's value. -func (s *GetPackageVersionAssetOutput) SetAssetName(v string) *GetPackageVersionAssetOutput { - s.AssetName = &v - return s +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListAllowedRepositoriesForGroupOutput) GoString() string { + return s.String() } -// SetPackageVersion sets the PackageVersion field's value. -func (s *GetPackageVersionAssetOutput) SetPackageVersion(v string) *GetPackageVersionAssetOutput { - s.PackageVersion = &v +// SetAllowedRepositories sets the AllowedRepositories field's value. +func (s *ListAllowedRepositoriesForGroupOutput) SetAllowedRepositories(v []*string) *ListAllowedRepositoriesForGroupOutput { + s.AllowedRepositories = v return s } -// SetPackageVersionRevision sets the PackageVersionRevision field's value. -func (s *GetPackageVersionAssetOutput) SetPackageVersionRevision(v string) *GetPackageVersionAssetOutput { - s.PackageVersionRevision = &v +// SetNextToken sets the NextToken field's value. +func (s *ListAllowedRepositoriesForGroupOutput) SetNextToken(v string) *ListAllowedRepositoriesForGroupOutput { + s.NextToken = &v return s } -type GetPackageVersionReadmeInput struct { +type ListAssociatedPackagesInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository that contains the package - // version with the requested readme file. + // The name of the domain that contains the package group from which to list + // associated packages. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -7379,36 +10016,22 @@ type GetPackageVersionReadmeInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // A format that specifies the type of the package version with the requested - // readme file. - // - // Format is a required field - Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - - // The namespace of the package version with the requested readme file. The - // package version component that specifies its namespace depends on its type. - // For example: - // - // * The namespace of an npm package version is its scope. - // - // * Python and NuGet package versions do not contain a corresponding component, - // package versions of those formats do not have a namespace. - Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` + // The maximum number of results to return per page. + MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` - // The name of the package version that contains the requested readme file. - // - // Package is a required field - Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` - // A string that contains the package version (for example, 3.5.2). + // The pattern of the package group from which to list associated packages. // - // PackageVersion is a required field - PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` + // PackageGroup is a required field + PackageGroup *string `location:"querystring" locationName:"package-group" min:"2" type:"string" required:"true"` - // The repository that contains the package with the requested readme file. - // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + // When this flag is included, ListAssociatedPackages will return a list of + // packages that would be associated with a package group, even if it does not + // exist. + Preview *bool `location:"querystring" locationName:"preview" type:"boolean"` } // String returns the string representation. @@ -7416,7 +10039,7 @@ type GetPackageVersionReadmeInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetPackageVersionReadmeInput) String() string { +func (s ListAssociatedPackagesInput) String() string { return awsutil.Prettify(s) } @@ -7425,13 +10048,13 @@ func (s GetPackageVersionReadmeInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetPackageVersionReadmeInput) GoString() string { +func (s ListAssociatedPackagesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetPackageVersionReadmeInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetPackageVersionReadmeInput"} +func (s *ListAssociatedPackagesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListAssociatedPackagesInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -7441,29 +10064,17 @@ func (s *GetPackageVersionReadmeInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Format == nil { - invalidParams.Add(request.NewErrParamRequired("Format")) - } - if s.Namespace != nil && len(*s.Namespace) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) - } - if s.Package == nil { - invalidParams.Add(request.NewErrParamRequired("Package")) - } - if s.Package != nil && len(*s.Package) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Package", 1)) - } - if s.PackageVersion == nil { - invalidParams.Add(request.NewErrParamRequired("PackageVersion")) + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) + if s.PackageGroup == nil { + invalidParams.Add(request.NewErrParamRequired("PackageGroup")) } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + if s.PackageGroup != nil && len(*s.PackageGroup) < 2 { + invalidParams.Add(request.NewErrParamMinLen("PackageGroup", 2)) } if invalidParams.Len() > 0 { @@ -7473,76 +10084,91 @@ func (s *GetPackageVersionReadmeInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *GetPackageVersionReadmeInput) SetDomain(v string) *GetPackageVersionReadmeInput { +func (s *ListAssociatedPackagesInput) SetDomain(v string) *ListAssociatedPackagesInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *GetPackageVersionReadmeInput) SetDomainOwner(v string) *GetPackageVersionReadmeInput { +func (s *ListAssociatedPackagesInput) SetDomainOwner(v string) *ListAssociatedPackagesInput { s.DomainOwner = &v return s } -// SetFormat sets the Format field's value. -func (s *GetPackageVersionReadmeInput) SetFormat(v string) *GetPackageVersionReadmeInput { - s.Format = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListAssociatedPackagesInput) SetMaxResults(v int64) *ListAssociatedPackagesInput { + s.MaxResults = &v return s } -// SetNamespace sets the Namespace field's value. -func (s *GetPackageVersionReadmeInput) SetNamespace(v string) *GetPackageVersionReadmeInput { - s.Namespace = &v +// SetNextToken sets the NextToken field's value. +func (s *ListAssociatedPackagesInput) SetNextToken(v string) *ListAssociatedPackagesInput { + s.NextToken = &v return s } -// SetPackage sets the Package field's value. -func (s *GetPackageVersionReadmeInput) SetPackage(v string) *GetPackageVersionReadmeInput { - s.Package = &v +// SetPackageGroup sets the PackageGroup field's value. +func (s *ListAssociatedPackagesInput) SetPackageGroup(v string) *ListAssociatedPackagesInput { + s.PackageGroup = &v return s } -// SetPackageVersion sets the PackageVersion field's value. -func (s *GetPackageVersionReadmeInput) SetPackageVersion(v string) *GetPackageVersionReadmeInput { - s.PackageVersion = &v +// SetPreview sets the Preview field's value. +func (s *ListAssociatedPackagesInput) SetPreview(v bool) *ListAssociatedPackagesInput { + s.Preview = &v return s } -// SetRepository sets the Repository field's value. -func (s *GetPackageVersionReadmeInput) SetRepository(v string) *GetPackageVersionReadmeInput { - s.Repository = &v - return s +type ListAssociatedPackagesOutput struct { + _ struct{} `type:"structure"` + + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` + + // The list of packages associated with the requested package group. + Packages []*AssociatedPackage `locationName:"packages" type:"list"` } -type GetPackageVersionReadmeOutput struct { - _ struct{} `type:"structure"` +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListAssociatedPackagesOutput) String() string { + return awsutil.Prettify(s) +} - // The format of the package with the requested readme file. - Format *string `locationName:"format" type:"string" enum:"PackageFormat"` +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListAssociatedPackagesOutput) GoString() string { + return s.String() +} - // The namespace of the package version with the requested readme file. The - // package version component that specifies its namespace depends on its type. - // For example: - // - // * The namespace of a Maven package version is its groupId. - // - // * The namespace of an npm package version is its scope. - // - // * Python and NuGet package versions do not contain a corresponding component, - // package versions of those formats do not have a namespace. - Namespace *string `locationName:"namespace" min:"1" type:"string"` +// SetNextToken sets the NextToken field's value. +func (s *ListAssociatedPackagesOutput) SetNextToken(v string) *ListAssociatedPackagesOutput { + s.NextToken = &v + return s +} - // The name of the package that contains the returned readme file. - Package *string `locationName:"package" min:"1" type:"string"` +// SetPackages sets the Packages field's value. +func (s *ListAssociatedPackagesOutput) SetPackages(v []*AssociatedPackage) *ListAssociatedPackagesOutput { + s.Packages = v + return s +} - // The text of the returned readme file. - Readme *string `locationName:"readme" type:"string"` +type ListDomainsInput struct { + _ struct{} `type:"structure"` - // The version of the package with the requested readme file. - Version *string `locationName:"version" min:"1" type:"string"` + // The maximum number of results to return per page. + MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` - // The current revision associated with the package version. - VersionRevision *string `locationName:"versionRevision" min:"1" type:"string"` + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } // String returns the string representation. @@ -7550,7 +10176,7 @@ type GetPackageVersionReadmeOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetPackageVersionReadmeOutput) String() string { +func (s ListDomainsInput) String() string { return awsutil.Prettify(s) } @@ -7559,68 +10185,102 @@ func (s GetPackageVersionReadmeOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetPackageVersionReadmeOutput) GoString() string { +func (s ListDomainsInput) GoString() string { return s.String() } -// SetFormat sets the Format field's value. -func (s *GetPackageVersionReadmeOutput) SetFormat(v string) *GetPackageVersionReadmeOutput { - s.Format = &v - return s +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListDomainsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListDomainsInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetNamespace sets the Namespace field's value. -func (s *GetPackageVersionReadmeOutput) SetNamespace(v string) *GetPackageVersionReadmeOutput { - s.Namespace = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListDomainsInput) SetMaxResults(v int64) *ListDomainsInput { + s.MaxResults = &v return s } -// SetPackage sets the Package field's value. -func (s *GetPackageVersionReadmeOutput) SetPackage(v string) *GetPackageVersionReadmeOutput { - s.Package = &v +// SetNextToken sets the NextToken field's value. +func (s *ListDomainsInput) SetNextToken(v string) *ListDomainsInput { + s.NextToken = &v return s } -// SetReadme sets the Readme field's value. -func (s *GetPackageVersionReadmeOutput) SetReadme(v string) *GetPackageVersionReadmeOutput { - s.Readme = &v - return s +type ListDomainsOutput struct { + _ struct{} `type:"structure"` + + // The returned list of DomainSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_DomainSummary.html) + // objects. + Domains []*DomainSummary `locationName:"domains" type:"list"` + + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` } -// SetVersion sets the Version field's value. -func (s *GetPackageVersionReadmeOutput) SetVersion(v string) *GetPackageVersionReadmeOutput { - s.Version = &v +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListDomainsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListDomainsOutput) GoString() string { + return s.String() +} + +// SetDomains sets the Domains field's value. +func (s *ListDomainsOutput) SetDomains(v []*DomainSummary) *ListDomainsOutput { + s.Domains = v return s } -// SetVersionRevision sets the VersionRevision field's value. -func (s *GetPackageVersionReadmeOutput) SetVersionRevision(v string) *GetPackageVersionReadmeOutput { - s.VersionRevision = &v +// SetNextToken sets the NextToken field's value. +func (s *ListDomainsOutput) SetNextToken(v string) *ListDomainsOutput { + s.NextToken = &v return s } -type GetRepositoryEndpointInput struct { +type ListPackageGroupsInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository. + // The domain for which you want to list package groups. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` // The 12-digit account number of the Amazon Web Services account that owns - // the domain that contains the repository. It does not include dashes or spaces. + // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // Returns which endpoint of a repository to return. A repository has one endpoint - // for each package format. - // - // Format is a required field - Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` + // The maximum number of results to return per page. + MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` - // The name of the repository. - // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` + + // A prefix for which to search package groups. When included, ListPackageGroups + // will return only package groups with patterns that match the prefix. + Prefix *string `location:"querystring" locationName:"prefix" type:"string"` } // String returns the string representation. @@ -7628,7 +10288,7 @@ type GetRepositoryEndpointInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetRepositoryEndpointInput) String() string { +func (s ListPackageGroupsInput) String() string { return awsutil.Prettify(s) } @@ -7637,13 +10297,13 @@ func (s GetRepositoryEndpointInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetRepositoryEndpointInput) GoString() string { +func (s ListPackageGroupsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetRepositoryEndpointInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetRepositoryEndpointInput"} +func (s *ListPackageGroupsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListPackageGroupsInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -7653,14 +10313,11 @@ func (s *GetRepositoryEndpointInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Format == nil { - invalidParams.Add(request.NewErrParamRequired("Format")) - } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } if invalidParams.Len() > 0 { @@ -7670,34 +10327,44 @@ func (s *GetRepositoryEndpointInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *GetRepositoryEndpointInput) SetDomain(v string) *GetRepositoryEndpointInput { +func (s *ListPackageGroupsInput) SetDomain(v string) *ListPackageGroupsInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *GetRepositoryEndpointInput) SetDomainOwner(v string) *GetRepositoryEndpointInput { +func (s *ListPackageGroupsInput) SetDomainOwner(v string) *ListPackageGroupsInput { s.DomainOwner = &v return s } -// SetFormat sets the Format field's value. -func (s *GetRepositoryEndpointInput) SetFormat(v string) *GetRepositoryEndpointInput { - s.Format = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListPackageGroupsInput) SetMaxResults(v int64) *ListPackageGroupsInput { + s.MaxResults = &v return s } -// SetRepository sets the Repository field's value. -func (s *GetRepositoryEndpointInput) SetRepository(v string) *GetRepositoryEndpointInput { - s.Repository = &v +// SetNextToken sets the NextToken field's value. +func (s *ListPackageGroupsInput) SetNextToken(v string) *ListPackageGroupsInput { + s.NextToken = &v return s } -type GetRepositoryEndpointOutput struct { +// SetPrefix sets the Prefix field's value. +func (s *ListPackageGroupsInput) SetPrefix(v string) *ListPackageGroupsInput { + s.Prefix = &v + return s +} + +type ListPackageGroupsOutput struct { _ struct{} `type:"structure"` - // A string that specifies the URL of the returned endpoint. - RepositoryEndpoint *string `locationName:"repositoryEndpoint" type:"string"` + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` + + // The list of package groups in the requested domain. + PackageGroups []*PackageGroupSummary `locationName:"packageGroups" type:"list"` } // String returns the string representation. @@ -7705,7 +10372,7 @@ type GetRepositoryEndpointOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetRepositoryEndpointOutput) String() string { +func (s ListPackageGroupsOutput) String() string { return awsutil.Prettify(s) } @@ -7714,21 +10381,27 @@ func (s GetRepositoryEndpointOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetRepositoryEndpointOutput) GoString() string { +func (s ListPackageGroupsOutput) GoString() string { return s.String() } -// SetRepositoryEndpoint sets the RepositoryEndpoint field's value. -func (s *GetRepositoryEndpointOutput) SetRepositoryEndpoint(v string) *GetRepositoryEndpointOutput { - s.RepositoryEndpoint = &v +// SetNextToken sets the NextToken field's value. +func (s *ListPackageGroupsOutput) SetNextToken(v string) *ListPackageGroupsOutput { + s.NextToken = &v return s } -type GetRepositoryPermissionsPolicyInput struct { +// SetPackageGroups sets the PackageGroups field's value. +func (s *ListPackageGroupsOutput) SetPackageGroups(v []*PackageGroupSummary) *ListPackageGroupsOutput { + s.PackageGroups = v + return s +} + +type ListPackageVersionAssetsInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain containing the repository whose associated resource - // policy is to be retrieved. + // The name of the domain that contains the repository associated with the package + // version assets. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -7737,7 +10410,53 @@ type GetRepositoryPermissionsPolicyInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The name of the repository whose associated resource policy is to be retrieved. + // The format of the package that contains the requested package version assets. + // + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` + + // The maximum number of results to return per page. + MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` + + // The namespace of the package version that contains the requested package + // version assets. The package component that specifies its namespace depends + // on its type. For example: + // + // The namespace is required requesting assets from package versions of the + // following formats: + // + // * Maven + // + // * Swift + // + // * generic + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` + + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` + + // The name of the package that contains the requested package version assets. + // + // Package is a required field + Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + + // A string that contains the package version (for example, 3.5.2). + // + // PackageVersion is a required field + PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` + + // The name of the repository that contains the package that contains the requested + // package version assets. // // Repository is a required field Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` @@ -7748,7 +10467,7 @@ type GetRepositoryPermissionsPolicyInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetRepositoryPermissionsPolicyInput) String() string { +func (s ListPackageVersionAssetsInput) String() string { return awsutil.Prettify(s) } @@ -7757,13 +10476,13 @@ func (s GetRepositoryPermissionsPolicyInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s GetRepositoryPermissionsPolicyInput) GoString() string { +func (s ListPackageVersionAssetsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *GetRepositoryPermissionsPolicyInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "GetRepositoryPermissionsPolicyInput"} +func (s *ListPackageVersionAssetsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListPackageVersionAssetsInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -7773,6 +10492,30 @@ func (s *GetRepositoryPermissionsPolicyInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) + } + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } + if s.Package == nil { + invalidParams.Add(request.NewErrParamRequired("Package")) + } + if s.Package != nil && len(*s.Package) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + } + if s.PackageVersion == nil { + invalidParams.Add(request.NewErrParamRequired("PackageVersion")) + } + if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) + } if s.Repository == nil { invalidParams.Add(request.NewErrParamRequired("Repository")) } @@ -7787,127 +10530,94 @@ func (s *GetRepositoryPermissionsPolicyInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *GetRepositoryPermissionsPolicyInput) SetDomain(v string) *GetRepositoryPermissionsPolicyInput { +func (s *ListPackageVersionAssetsInput) SetDomain(v string) *ListPackageVersionAssetsInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *GetRepositoryPermissionsPolicyInput) SetDomainOwner(v string) *GetRepositoryPermissionsPolicyInput { +func (s *ListPackageVersionAssetsInput) SetDomainOwner(v string) *ListPackageVersionAssetsInput { s.DomainOwner = &v return s } -// SetRepository sets the Repository field's value. -func (s *GetRepositoryPermissionsPolicyInput) SetRepository(v string) *GetRepositoryPermissionsPolicyInput { - s.Repository = &v +// SetFormat sets the Format field's value. +func (s *ListPackageVersionAssetsInput) SetFormat(v string) *ListPackageVersionAssetsInput { + s.Format = &v return s } -type GetRepositoryPermissionsPolicyOutput struct { - _ struct{} `type:"structure"` - - // The returned resource policy. - Policy *ResourcePolicy `locationName:"policy" type:"structure"` -} - -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GetRepositoryPermissionsPolicyOutput) String() string { - return awsutil.Prettify(s) -} - -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s GetRepositoryPermissionsPolicyOutput) GoString() string { - return s.String() -} - -// SetPolicy sets the Policy field's value. -func (s *GetRepositoryPermissionsPolicyOutput) SetPolicy(v *ResourcePolicy) *GetRepositoryPermissionsPolicyOutput { - s.Policy = v +// SetMaxResults sets the MaxResults field's value. +func (s *ListPackageVersionAssetsInput) SetMaxResults(v int64) *ListPackageVersionAssetsInput { + s.MaxResults = &v return s } -// The operation did not succeed because of an error that occurred inside CodeArtifact. -type InternalServerException struct { - _ struct{} `type:"structure"` - RespMetadata protocol.ResponseMetadata `json:"-" xml:"-"` - - Message_ *string `locationName:"message" type:"string"` +// SetNamespace sets the Namespace field's value. +func (s *ListPackageVersionAssetsInput) SetNamespace(v string) *ListPackageVersionAssetsInput { + s.Namespace = &v + return s } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s InternalServerException) String() string { - return awsutil.Prettify(s) +// SetNextToken sets the NextToken field's value. +func (s *ListPackageVersionAssetsInput) SetNextToken(v string) *ListPackageVersionAssetsInput { + s.NextToken = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s InternalServerException) GoString() string { - return s.String() +// SetPackage sets the Package field's value. +func (s *ListPackageVersionAssetsInput) SetPackage(v string) *ListPackageVersionAssetsInput { + s.Package = &v + return s } -func newErrorInternalServerException(v protocol.ResponseMetadata) error { - return &InternalServerException{ - RespMetadata: v, - } +// SetPackageVersion sets the PackageVersion field's value. +func (s *ListPackageVersionAssetsInput) SetPackageVersion(v string) *ListPackageVersionAssetsInput { + s.PackageVersion = &v + return s } -// Code returns the exception type name. -func (s *InternalServerException) Code() string { - return "InternalServerException" +// SetRepository sets the Repository field's value. +func (s *ListPackageVersionAssetsInput) SetRepository(v string) *ListPackageVersionAssetsInput { + s.Repository = &v + return s } -// Message returns the exception's message. -func (s *InternalServerException) Message() string { - if s.Message_ != nil { - return *s.Message_ - } - return "" -} +type ListPackageVersionAssetsOutput struct { + _ struct{} `type:"structure"` -// OrigErr always returns nil, satisfies awserr.Error interface. -func (s *InternalServerException) OrigErr() error { - return nil -} + // The returned list of AssetSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_AssetSummary.html) + // objects. + Assets []*AssetSummary `locationName:"assets" type:"list"` -func (s *InternalServerException) Error() string { - return fmt.Sprintf("%s: %s", s.Code(), s.Message()) -} + // The format of the package that contains the requested package version assets. + Format *string `locationName:"format" type:"string" enum:"PackageFormat"` -// Status code returns the HTTP status code for the request's response error. -func (s *InternalServerException) StatusCode() int { - return s.RespMetadata.StatusCode -} + // The namespace of the package version that contains the requested package + // version assets. The package component that specifies its namespace depends + // on its type. For example: + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `locationName:"namespace" min:"1" type:"string"` -// RequestID returns the service's response RequestID for request. -func (s *InternalServerException) RequestID() string { - return s.RespMetadata.RequestID -} + // If there are additional results, this is the token for the next set of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` -// Details of the license data. -type LicenseInfo struct { - _ struct{} `type:"structure"` + // The name of the package that contains the requested package version assets. + Package *string `locationName:"package" min:"1" type:"string"` - // Name of the license. - Name *string `locationName:"name" type:"string"` + // The version of the package associated with the requested assets. + Version *string `locationName:"version" min:"1" type:"string"` - // The URL for license data. - Url *string `locationName:"url" type:"string"` + // The current revision associated with the package version. + VersionRevision *string `locationName:"versionRevision" min:"1" type:"string"` } // String returns the string representation. @@ -7915,7 +10625,7 @@ type LicenseInfo struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s LicenseInfo) String() string { +func (s ListPackageVersionAssetsOutput) String() string { return awsutil.Prettify(s) } @@ -7924,31 +10634,110 @@ func (s LicenseInfo) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s LicenseInfo) GoString() string { +func (s ListPackageVersionAssetsOutput) GoString() string { return s.String() } -// SetName sets the Name field's value. -func (s *LicenseInfo) SetName(v string) *LicenseInfo { - s.Name = &v +// SetAssets sets the Assets field's value. +func (s *ListPackageVersionAssetsOutput) SetAssets(v []*AssetSummary) *ListPackageVersionAssetsOutput { + s.Assets = v return s } -// SetUrl sets the Url field's value. -func (s *LicenseInfo) SetUrl(v string) *LicenseInfo { - s.Url = &v +// SetFormat sets the Format field's value. +func (s *ListPackageVersionAssetsOutput) SetFormat(v string) *ListPackageVersionAssetsOutput { + s.Format = &v return s } -type ListDomainsInput struct { - _ struct{} `type:"structure"` +// SetNamespace sets the Namespace field's value. +func (s *ListPackageVersionAssetsOutput) SetNamespace(v string) *ListPackageVersionAssetsOutput { + s.Namespace = &v + return s +} - // The maximum number of results to return per page. - MaxResults *int64 `locationName:"maxResults" min:"1" type:"integer"` +// SetNextToken sets the NextToken field's value. +func (s *ListPackageVersionAssetsOutput) SetNextToken(v string) *ListPackageVersionAssetsOutput { + s.NextToken = &v + return s +} + +// SetPackage sets the Package field's value. +func (s *ListPackageVersionAssetsOutput) SetPackage(v string) *ListPackageVersionAssetsOutput { + s.Package = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *ListPackageVersionAssetsOutput) SetVersion(v string) *ListPackageVersionAssetsOutput { + s.Version = &v + return s +} + +// SetVersionRevision sets the VersionRevision field's value. +func (s *ListPackageVersionAssetsOutput) SetVersionRevision(v string) *ListPackageVersionAssetsOutput { + s.VersionRevision = &v + return s +} + +type ListPackageVersionDependenciesInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The name of the domain that contains the repository that contains the requested + // package version dependencies. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The format of the package with the requested dependencies. + // + // Format is a required field + Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` + + // The namespace of the package version with the requested dependencies. The + // package component that specifies its namespace depends on its type. For example: + // + // The namespace is required when listing dependencies from package versions + // of the following formats: + // + // * Maven + // + // * Swift + // + // * generic + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` // The token for the next set of results. Use the value returned in the previous // response in the next request to retrieve the next set of results. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` + + // The name of the package versions' package. + // + // Package is a required field + Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + + // A string that contains the package version (for example, 3.5.2). + // + // PackageVersion is a required field + PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` + + // The name of the repository that contains the requested package version. + // + // Repository is a required field + Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -7956,7 +10745,7 @@ type ListDomainsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListDomainsInput) String() string { +func (s ListPackageVersionDependenciesInput) String() string { return awsutil.Prettify(s) } @@ -7965,19 +10754,49 @@ func (s ListDomainsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListDomainsInput) GoString() string { +func (s ListPackageVersionDependenciesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListDomainsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListDomainsInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) +func (s *ListPackageVersionDependenciesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListPackageVersionDependenciesInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.Format == nil { + invalidParams.Add(request.NewErrParamRequired("Format")) + } + if s.Namespace != nil && len(*s.Namespace) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) } if s.NextToken != nil && len(*s.NextToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } + if s.Package == nil { + invalidParams.Add(request.NewErrParamRequired("Package")) + } + if s.Package != nil && len(*s.Package) < 1 { + invalidParams.Add(request.NewErrParamMinLen("Package", 1)) + } + if s.PackageVersion == nil { + invalidParams.Add(request.NewErrParamRequired("PackageVersion")) + } + if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) + } + if s.Repository == nil { + invalidParams.Add(request.NewErrParamRequired("Repository")) + } + if s.Repository != nil && len(*s.Repository) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + } if invalidParams.Len() > 0 { return invalidParams @@ -7985,28 +10804,91 @@ func (s *ListDomainsInput) Validate() error { return nil } -// SetMaxResults sets the MaxResults field's value. -func (s *ListDomainsInput) SetMaxResults(v int64) *ListDomainsInput { - s.MaxResults = &v +// SetDomain sets the Domain field's value. +func (s *ListPackageVersionDependenciesInput) SetDomain(v string) *ListPackageVersionDependenciesInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *ListPackageVersionDependenciesInput) SetDomainOwner(v string) *ListPackageVersionDependenciesInput { + s.DomainOwner = &v + return s +} + +// SetFormat sets the Format field's value. +func (s *ListPackageVersionDependenciesInput) SetFormat(v string) *ListPackageVersionDependenciesInput { + s.Format = &v + return s +} + +// SetNamespace sets the Namespace field's value. +func (s *ListPackageVersionDependenciesInput) SetNamespace(v string) *ListPackageVersionDependenciesInput { + s.Namespace = &v return s } // SetNextToken sets the NextToken field's value. -func (s *ListDomainsInput) SetNextToken(v string) *ListDomainsInput { +func (s *ListPackageVersionDependenciesInput) SetNextToken(v string) *ListPackageVersionDependenciesInput { s.NextToken = &v return s } -type ListDomainsOutput struct { +// SetPackage sets the Package field's value. +func (s *ListPackageVersionDependenciesInput) SetPackage(v string) *ListPackageVersionDependenciesInput { + s.Package = &v + return s +} + +// SetPackageVersion sets the PackageVersion field's value. +func (s *ListPackageVersionDependenciesInput) SetPackageVersion(v string) *ListPackageVersionDependenciesInput { + s.PackageVersion = &v + return s +} + +// SetRepository sets the Repository field's value. +func (s *ListPackageVersionDependenciesInput) SetRepository(v string) *ListPackageVersionDependenciesInput { + s.Repository = &v + return s +} + +type ListPackageVersionDependenciesOutput struct { _ struct{} `type:"structure"` - // The returned list of DomainSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_DomainSummary.html) + // The returned list of PackageDependency (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageDependency.html) // objects. - Domains []*DomainSummary `locationName:"domains" type:"list"` + Dependencies []*PackageDependency `locationName:"dependencies" type:"list"` + + // A format that specifies the type of the package that contains the returned + // dependencies. + Format *string `locationName:"format" type:"string" enum:"PackageFormat"` + + // The namespace of the package version that contains the returned dependencies. + // The package component that specifies its namespace depends on its type. For + // example: + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `locationName:"namespace" min:"1" type:"string"` // The token for the next set of results. Use the value returned in the previous // response in the next request to retrieve the next set of results. NextToken *string `locationName:"nextToken" min:"1" type:"string"` + + // The name of the package that contains the returned package versions dependencies. + Package *string `locationName:"package" min:"1" type:"string"` + + // The version of the package that is specified in the request. + Version *string `locationName:"version" min:"1" type:"string"` + + // The current revision associated with the package version. + VersionRevision *string `locationName:"versionRevision" min:"1" type:"string"` } // String returns the string representation. @@ -8014,7 +10896,7 @@ type ListDomainsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListDomainsOutput) String() string { +func (s ListPackageVersionDependenciesOutput) String() string { return awsutil.Prettify(s) } @@ -8023,27 +10905,57 @@ func (s ListDomainsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListDomainsOutput) GoString() string { +func (s ListPackageVersionDependenciesOutput) GoString() string { return s.String() } -// SetDomains sets the Domains field's value. -func (s *ListDomainsOutput) SetDomains(v []*DomainSummary) *ListDomainsOutput { - s.Domains = v +// SetDependencies sets the Dependencies field's value. +func (s *ListPackageVersionDependenciesOutput) SetDependencies(v []*PackageDependency) *ListPackageVersionDependenciesOutput { + s.Dependencies = v + return s +} + +// SetFormat sets the Format field's value. +func (s *ListPackageVersionDependenciesOutput) SetFormat(v string) *ListPackageVersionDependenciesOutput { + s.Format = &v + return s +} + +// SetNamespace sets the Namespace field's value. +func (s *ListPackageVersionDependenciesOutput) SetNamespace(v string) *ListPackageVersionDependenciesOutput { + s.Namespace = &v return s } // SetNextToken sets the NextToken field's value. -func (s *ListDomainsOutput) SetNextToken(v string) *ListDomainsOutput { +func (s *ListPackageVersionDependenciesOutput) SetNextToken(v string) *ListPackageVersionDependenciesOutput { s.NextToken = &v return s } -type ListPackageVersionAssetsInput struct { +// SetPackage sets the Package field's value. +func (s *ListPackageVersionDependenciesOutput) SetPackage(v string) *ListPackageVersionDependenciesOutput { + s.Package = &v + return s +} + +// SetVersion sets the Version field's value. +func (s *ListPackageVersionDependenciesOutput) SetVersion(v string) *ListPackageVersionDependenciesOutput { + s.Version = &v + return s +} + +// SetVersionRevision sets the VersionRevision field's value. +func (s *ListPackageVersionDependenciesOutput) SetVersionRevision(v string) *ListPackageVersionDependenciesOutput { + s.VersionRevision = &v + return s +} + +type ListPackageVersionsInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository associated with the package - // version assets. + // The name of the domain that contains the repository that contains the requested + // package versions. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -8052,7 +10964,7 @@ type ListPackageVersionAssetsInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The format of the package that contains the requested package version assets. + // The format of the package versions you want to list. // // Format is a required field Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` @@ -8060,39 +10972,52 @@ type ListPackageVersionAssetsInput struct { // The maximum number of results to return per page. MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` - // The namespace of the package version that contains the requested package - // version assets. The package version component that specifies its namespace - // depends on its type. For example: + // The namespace of the package that contains the requested package versions. + // The package component that specifies its namespace depends on its type. For + // example: + // + // The namespace is required when deleting package versions of the following + // formats: + // + // * Maven + // + // * Swift + // + // * generic // // * The namespace of a Maven package version is its groupId. // - // * The namespace of an npm package version is its scope. + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. // // * Python and NuGet package versions do not contain a corresponding component, // package versions of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` // The token for the next set of results. Use the value returned in the previous // response in the next request to retrieve the next set of results. NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` - // The name of the package that contains the requested package version assets. + // The originType used to filter package versions. Only package versions with + // the provided originType will be returned. + OriginType *string `location:"querystring" locationName:"originType" type:"string" enum:"PackageVersionOriginType"` + + // The name of the package for which you want to request package versions. // // Package is a required field Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` - // A string that contains the package version (for example, 3.5.2). - // - // PackageVersion is a required field - PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` - - // The name of the repository that contains the package that contains the requested - // package version assets. + // The name of the repository that contains the requested package versions. // // Repository is a required field Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + + // How to sort the requested list of package versions. + SortBy *string `location:"querystring" locationName:"sortBy" type:"string" enum:"PackageVersionSortType"` + + // A string that filters the requested package versions by status. + Status *string `location:"querystring" locationName:"status" type:"string" enum:"PackageVersionStatus"` } // String returns the string representation. @@ -8100,7 +11025,7 @@ type ListPackageVersionAssetsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionAssetsInput) String() string { +func (s ListPackageVersionsInput) String() string { return awsutil.Prettify(s) } @@ -8109,13 +11034,13 @@ func (s ListPackageVersionAssetsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionAssetsInput) GoString() string { +func (s ListPackageVersionsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListPackageVersionAssetsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListPackageVersionAssetsInput"} +func (s *ListPackageVersionsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListPackageVersionsInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -8143,12 +11068,6 @@ func (s *ListPackageVersionAssetsInput) Validate() error { if s.Package != nil && len(*s.Package) < 1 { invalidParams.Add(request.NewErrParamMinLen("Package", 1)) } - if s.PackageVersion == nil { - invalidParams.Add(request.NewErrParamRequired("PackageVersion")) - } - if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) - } if s.Repository == nil { invalidParams.Add(request.NewErrParamRequired("Repository")) } @@ -8163,76 +11082,95 @@ func (s *ListPackageVersionAssetsInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *ListPackageVersionAssetsInput) SetDomain(v string) *ListPackageVersionAssetsInput { +func (s *ListPackageVersionsInput) SetDomain(v string) *ListPackageVersionsInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *ListPackageVersionAssetsInput) SetDomainOwner(v string) *ListPackageVersionAssetsInput { +func (s *ListPackageVersionsInput) SetDomainOwner(v string) *ListPackageVersionsInput { s.DomainOwner = &v return s } // SetFormat sets the Format field's value. -func (s *ListPackageVersionAssetsInput) SetFormat(v string) *ListPackageVersionAssetsInput { +func (s *ListPackageVersionsInput) SetFormat(v string) *ListPackageVersionsInput { s.Format = &v return s } // SetMaxResults sets the MaxResults field's value. -func (s *ListPackageVersionAssetsInput) SetMaxResults(v int64) *ListPackageVersionAssetsInput { +func (s *ListPackageVersionsInput) SetMaxResults(v int64) *ListPackageVersionsInput { s.MaxResults = &v return s } // SetNamespace sets the Namespace field's value. -func (s *ListPackageVersionAssetsInput) SetNamespace(v string) *ListPackageVersionAssetsInput { +func (s *ListPackageVersionsInput) SetNamespace(v string) *ListPackageVersionsInput { s.Namespace = &v return s } // SetNextToken sets the NextToken field's value. -func (s *ListPackageVersionAssetsInput) SetNextToken(v string) *ListPackageVersionAssetsInput { +func (s *ListPackageVersionsInput) SetNextToken(v string) *ListPackageVersionsInput { s.NextToken = &v return s } -// SetPackage sets the Package field's value. -func (s *ListPackageVersionAssetsInput) SetPackage(v string) *ListPackageVersionAssetsInput { - s.Package = &v +// SetOriginType sets the OriginType field's value. +func (s *ListPackageVersionsInput) SetOriginType(v string) *ListPackageVersionsInput { + s.OriginType = &v return s } -// SetPackageVersion sets the PackageVersion field's value. -func (s *ListPackageVersionAssetsInput) SetPackageVersion(v string) *ListPackageVersionAssetsInput { - s.PackageVersion = &v +// SetPackage sets the Package field's value. +func (s *ListPackageVersionsInput) SetPackage(v string) *ListPackageVersionsInput { + s.Package = &v return s } // SetRepository sets the Repository field's value. -func (s *ListPackageVersionAssetsInput) SetRepository(v string) *ListPackageVersionAssetsInput { +func (s *ListPackageVersionsInput) SetRepository(v string) *ListPackageVersionsInput { s.Repository = &v return s } -type ListPackageVersionAssetsOutput struct { +// SetSortBy sets the SortBy field's value. +func (s *ListPackageVersionsInput) SetSortBy(v string) *ListPackageVersionsInput { + s.SortBy = &v + return s +} + +// SetStatus sets the Status field's value. +func (s *ListPackageVersionsInput) SetStatus(v string) *ListPackageVersionsInput { + s.Status = &v + return s +} + +type ListPackageVersionsOutput struct { _ struct{} `type:"structure"` - // The returned list of AssetSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_AssetSummary.html) - // objects. - Assets []*AssetSummary `locationName:"assets" type:"list"` + // The default package version to display. This depends on the package format: + // + // * For Maven and PyPI packages, it's the most recently published package + // version. + // + // * For npm packages, it's the version referenced by the latest tag. If + // the latest tag is not set, it's the most recently published package version. + DefaultDisplayVersion *string `locationName:"defaultDisplayVersion" min:"1" type:"string"` - // The format of the package that contains the requested package version assets. + // A format of the package. Format *string `locationName:"format" type:"string" enum:"PackageFormat"` - // The namespace of the package version that contains the requested package - // version assets. The package version component that specifies its namespace - // depends on its type. For example: + // The namespace of the package that contains the requested package versions. + // The package component that specifies its namespace depends on its type. For + // example: // // * The namespace of a Maven package version is its groupId. // - // * The namespace of an npm package version is its scope. + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. // // * Python and NuGet package versions do not contain a corresponding component, // package versions of those formats do not have a namespace. @@ -8241,14 +11179,12 @@ type ListPackageVersionAssetsOutput struct { // If there are additional results, this is the token for the next set of results. NextToken *string `locationName:"nextToken" min:"1" type:"string"` - // The name of the package that contains the requested package version assets. + // The name of the package. Package *string `locationName:"package" min:"1" type:"string"` - // The version of the package associated with the requested assets. - Version *string `locationName:"version" min:"1" type:"string"` - - // The current revision associated with the package version. - VersionRevision *string `locationName:"versionRevision" min:"1" type:"string"` + // The returned list of PackageVersionSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionSummary.html) + // objects. + Versions []*PackageVersionSummary `locationName:"versions" type:"list"` } // String returns the string representation. @@ -8256,7 +11192,7 @@ type ListPackageVersionAssetsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionAssetsOutput) String() string { +func (s ListPackageVersionsOutput) String() string { return awsutil.Prettify(s) } @@ -8265,57 +11201,51 @@ func (s ListPackageVersionAssetsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionAssetsOutput) GoString() string { +func (s ListPackageVersionsOutput) GoString() string { return s.String() } -// SetAssets sets the Assets field's value. -func (s *ListPackageVersionAssetsOutput) SetAssets(v []*AssetSummary) *ListPackageVersionAssetsOutput { - s.Assets = v +// SetDefaultDisplayVersion sets the DefaultDisplayVersion field's value. +func (s *ListPackageVersionsOutput) SetDefaultDisplayVersion(v string) *ListPackageVersionsOutput { + s.DefaultDisplayVersion = &v return s } // SetFormat sets the Format field's value. -func (s *ListPackageVersionAssetsOutput) SetFormat(v string) *ListPackageVersionAssetsOutput { +func (s *ListPackageVersionsOutput) SetFormat(v string) *ListPackageVersionsOutput { s.Format = &v return s } // SetNamespace sets the Namespace field's value. -func (s *ListPackageVersionAssetsOutput) SetNamespace(v string) *ListPackageVersionAssetsOutput { +func (s *ListPackageVersionsOutput) SetNamespace(v string) *ListPackageVersionsOutput { s.Namespace = &v return s } // SetNextToken sets the NextToken field's value. -func (s *ListPackageVersionAssetsOutput) SetNextToken(v string) *ListPackageVersionAssetsOutput { +func (s *ListPackageVersionsOutput) SetNextToken(v string) *ListPackageVersionsOutput { s.NextToken = &v return s } // SetPackage sets the Package field's value. -func (s *ListPackageVersionAssetsOutput) SetPackage(v string) *ListPackageVersionAssetsOutput { +func (s *ListPackageVersionsOutput) SetPackage(v string) *ListPackageVersionsOutput { s.Package = &v return s } -// SetVersion sets the Version field's value. -func (s *ListPackageVersionAssetsOutput) SetVersion(v string) *ListPackageVersionAssetsOutput { - s.Version = &v - return s -} - -// SetVersionRevision sets the VersionRevision field's value. -func (s *ListPackageVersionAssetsOutput) SetVersionRevision(v string) *ListPackageVersionAssetsOutput { - s.VersionRevision = &v +// SetVersions sets the Versions field's value. +func (s *ListPackageVersionsOutput) SetVersions(v []*PackageVersionSummary) *ListPackageVersionsOutput { + s.Versions = v return s } -type ListPackageVersionDependenciesInput struct { +type ListPackagesInput struct { _ struct{} `type:"structure" nopayload:"true"` // The name of the domain that contains the repository that contains the requested - // package version dependencies. + // packages. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -8324,43 +11254,52 @@ type ListPackageVersionDependenciesInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The format of the package with the requested dependencies. - // - // Format is a required field - Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` + // The format used to filter requested packages. Only packages from the provided + // format will be returned. + Format *string `location:"querystring" locationName:"format" type:"string" enum:"PackageFormat"` - // The namespace of the package version with the requested dependencies. The - // package version component that specifies its namespace depends on its type. - // For example: + // The maximum number of results to return per page. + MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` + + // The namespace prefix used to filter requested packages. Only packages with + // a namespace that starts with the provided string value are returned. Note + // that although this option is called --namespace and not --namespace-prefix, + // it has prefix-matching behavior. + // + // Each package format uses namespace as follows: // // * The namespace of a Maven package version is its groupId. // - // * The namespace of an npm package version is its scope. + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. // // * Python and NuGet package versions do not contain a corresponding component, // package versions of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` // The token for the next set of results. Use the value returned in the previous // response in the next request to retrieve the next set of results. NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` - // The name of the package versions' package. - // - // Package is a required field - Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` + // A prefix used to filter requested packages. Only packages with names that + // start with packagePrefix are returned. + PackagePrefix *string `location:"querystring" locationName:"package-prefix" min:"1" type:"string"` - // A string that contains the package version (for example, 3.5.2). - // - // PackageVersion is a required field - PackageVersion *string `location:"querystring" locationName:"version" min:"1" type:"string" required:"true"` + // The value of the Publish package origin control restriction used to filter + // requested packages. Only packages with the provided restriction are returned. + // For more information, see PackageOriginRestrictions (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageOriginRestrictions.html). + Publish *string `location:"querystring" locationName:"publish" type:"string" enum:"AllowPublish"` - // The name of the repository that contains the requested package version. + // The name of the repository that contains the requested packages. // // Repository is a required field Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` + + // The value of the Upstream package origin control restriction used to filter + // requested packages. Only packages with the provided restriction are returned. + // For more information, see PackageOriginRestrictions (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageOriginRestrictions.html). + Upstream *string `location:"querystring" locationName:"upstream" type:"string" enum:"AllowUpstream"` } // String returns the string representation. @@ -8368,7 +11307,7 @@ type ListPackageVersionDependenciesInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionDependenciesInput) String() string { +func (s ListPackagesInput) String() string { return awsutil.Prettify(s) } @@ -8377,13 +11316,13 @@ func (s ListPackageVersionDependenciesInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionDependenciesInput) GoString() string { +func (s ListPackagesInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListPackageVersionDependenciesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListPackageVersionDependenciesInput"} +func (s *ListPackagesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListPackagesInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -8393,8 +11332,8 @@ func (s *ListPackageVersionDependenciesInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Format == nil { - invalidParams.Add(request.NewErrParamRequired("Format")) + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } if s.Namespace != nil && len(*s.Namespace) < 1 { invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) @@ -8402,17 +11341,8 @@ func (s *ListPackageVersionDependenciesInput) Validate() error { if s.NextToken != nil && len(*s.NextToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } - if s.Package == nil { - invalidParams.Add(request.NewErrParamRequired("Package")) - } - if s.Package != nil && len(*s.Package) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Package", 1)) - } - if s.PackageVersion == nil { - invalidParams.Add(request.NewErrParamRequired("PackageVersion")) - } - if s.PackageVersion != nil && len(*s.PackageVersion) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PackageVersion", 1)) + if s.PackagePrefix != nil && len(*s.PackagePrefix) < 1 { + invalidParams.Add(request.NewErrParamMinLen("PackagePrefix", 1)) } if s.Repository == nil { invalidParams.Add(request.NewErrParamRequired("Repository")) @@ -8428,88 +11358,74 @@ func (s *ListPackageVersionDependenciesInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *ListPackageVersionDependenciesInput) SetDomain(v string) *ListPackageVersionDependenciesInput { +func (s *ListPackagesInput) SetDomain(v string) *ListPackagesInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *ListPackageVersionDependenciesInput) SetDomainOwner(v string) *ListPackageVersionDependenciesInput { +func (s *ListPackagesInput) SetDomainOwner(v string) *ListPackagesInput { s.DomainOwner = &v return s } // SetFormat sets the Format field's value. -func (s *ListPackageVersionDependenciesInput) SetFormat(v string) *ListPackageVersionDependenciesInput { +func (s *ListPackagesInput) SetFormat(v string) *ListPackagesInput { s.Format = &v return s } +// SetMaxResults sets the MaxResults field's value. +func (s *ListPackagesInput) SetMaxResults(v int64) *ListPackagesInput { + s.MaxResults = &v + return s +} + // SetNamespace sets the Namespace field's value. -func (s *ListPackageVersionDependenciesInput) SetNamespace(v string) *ListPackageVersionDependenciesInput { +func (s *ListPackagesInput) SetNamespace(v string) *ListPackagesInput { s.Namespace = &v return s } // SetNextToken sets the NextToken field's value. -func (s *ListPackageVersionDependenciesInput) SetNextToken(v string) *ListPackageVersionDependenciesInput { +func (s *ListPackagesInput) SetNextToken(v string) *ListPackagesInput { s.NextToken = &v return s } -// SetPackage sets the Package field's value. -func (s *ListPackageVersionDependenciesInput) SetPackage(v string) *ListPackageVersionDependenciesInput { - s.Package = &v +// SetPackagePrefix sets the PackagePrefix field's value. +func (s *ListPackagesInput) SetPackagePrefix(v string) *ListPackagesInput { + s.PackagePrefix = &v + return s +} + +// SetPublish sets the Publish field's value. +func (s *ListPackagesInput) SetPublish(v string) *ListPackagesInput { + s.Publish = &v return s } -// SetPackageVersion sets the PackageVersion field's value. -func (s *ListPackageVersionDependenciesInput) SetPackageVersion(v string) *ListPackageVersionDependenciesInput { - s.PackageVersion = &v +// SetRepository sets the Repository field's value. +func (s *ListPackagesInput) SetRepository(v string) *ListPackagesInput { + s.Repository = &v return s } -// SetRepository sets the Repository field's value. -func (s *ListPackageVersionDependenciesInput) SetRepository(v string) *ListPackageVersionDependenciesInput { - s.Repository = &v +// SetUpstream sets the Upstream field's value. +func (s *ListPackagesInput) SetUpstream(v string) *ListPackagesInput { + s.Upstream = &v return s } -type ListPackageVersionDependenciesOutput struct { +type ListPackagesOutput struct { _ struct{} `type:"structure"` - // The returned list of PackageDependency (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageDependency.html) - // objects. - Dependencies []*PackageDependency `locationName:"dependencies" type:"list"` - - // A format that specifies the type of the package that contains the returned - // dependencies. - Format *string `locationName:"format" type:"string" enum:"PackageFormat"` - - // The namespace of the package version that contains the returned dependencies. - // The package version component that specifies its namespace depends on its - // type. For example: - // - // * The namespace of a Maven package version is its groupId. - // - // * The namespace of an npm package version is its scope. - // - // * Python and NuGet package versions do not contain a corresponding component, - // package versions of those formats do not have a namespace. - Namespace *string `locationName:"namespace" min:"1" type:"string"` - - // The token for the next set of results. Use the value returned in the previous - // response in the next request to retrieve the next set of results. + // If there are additional results, this is the token for the next set of results. NextToken *string `locationName:"nextToken" min:"1" type:"string"` - // The name of the package that contains the returned package versions dependencies. - Package *string `locationName:"package" min:"1" type:"string"` - - // The version of the package that is specified in the request. - Version *string `locationName:"version" min:"1" type:"string"` - - // The current revision associated with the package version. - VersionRevision *string `locationName:"versionRevision" min:"1" type:"string"` + // The list of returned PackageSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageSummary.html) + // objects. + Packages []*PackageSummary `locationName:"packages" type:"list"` } // String returns the string representation. @@ -8517,7 +11433,7 @@ type ListPackageVersionDependenciesOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionDependenciesOutput) String() string { +func (s ListPackagesOutput) String() string { return awsutil.Prettify(s) } @@ -8526,57 +11442,30 @@ func (s ListPackageVersionDependenciesOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionDependenciesOutput) GoString() string { +func (s ListPackagesOutput) GoString() string { return s.String() } -// SetDependencies sets the Dependencies field's value. -func (s *ListPackageVersionDependenciesOutput) SetDependencies(v []*PackageDependency) *ListPackageVersionDependenciesOutput { - s.Dependencies = v - return s -} - -// SetFormat sets the Format field's value. -func (s *ListPackageVersionDependenciesOutput) SetFormat(v string) *ListPackageVersionDependenciesOutput { - s.Format = &v - return s -} - -// SetNamespace sets the Namespace field's value. -func (s *ListPackageVersionDependenciesOutput) SetNamespace(v string) *ListPackageVersionDependenciesOutput { - s.Namespace = &v - return s -} - // SetNextToken sets the NextToken field's value. -func (s *ListPackageVersionDependenciesOutput) SetNextToken(v string) *ListPackageVersionDependenciesOutput { +func (s *ListPackagesOutput) SetNextToken(v string) *ListPackagesOutput { s.NextToken = &v return s } -// SetPackage sets the Package field's value. -func (s *ListPackageVersionDependenciesOutput) SetPackage(v string) *ListPackageVersionDependenciesOutput { - s.Package = &v - return s -} - -// SetVersion sets the Version field's value. -func (s *ListPackageVersionDependenciesOutput) SetVersion(v string) *ListPackageVersionDependenciesOutput { - s.Version = &v - return s -} - -// SetVersionRevision sets the VersionRevision field's value. -func (s *ListPackageVersionDependenciesOutput) SetVersionRevision(v string) *ListPackageVersionDependenciesOutput { - s.VersionRevision = &v +// SetPackages sets the Packages field's value. +func (s *ListPackagesOutput) SetPackages(v []*PackageSummary) *ListPackagesOutput { + s.Packages = v return s } -type ListPackageVersionsInput struct { +type ListRepositoriesInDomainInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository that contains the requested - // package versions. + // Filter the list of repositories to only include those that are managed by + // the Amazon Web Services account ID. + AdministratorAccount *string `location:"querystring" locationName:"administrator-account" min:"12" type:"string"` + + // The name of the domain that contains the returned list of repositories. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -8585,51 +11474,16 @@ type ListPackageVersionsInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The format of the package versions you want to list. - // - // Format is a required field - Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - // The maximum number of results to return per page. MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` - // The namespace of the package that contains the requested package versions. - // The package component that specifies its namespace depends on its type. For - // example: - // - // * The namespace of a Maven package is its groupId. - // - // * The namespace of an npm package is its scope. - // - // * Python and NuGet packages do not contain a corresponding component, - // packages of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. - Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - // The token for the next set of results. Use the value returned in the previous // response in the next request to retrieve the next set of results. NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` - // The originType used to filter package versions. Only package versions with - // the provided originType will be returned. - OriginType *string `location:"querystring" locationName:"originType" type:"string" enum:"PackageVersionOriginType"` - - // The name of the package for which you want to request package versions. - // - // Package is a required field - Package *string `location:"querystring" locationName:"package" min:"1" type:"string" required:"true"` - - // The name of the repository that contains the requested package versions. - // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` - - // How to sort the requested list of package versions. - SortBy *string `location:"querystring" locationName:"sortBy" type:"string" enum:"PackageVersionSortType"` - - // A string that filters the requested package versions by status. - Status *string `location:"querystring" locationName:"status" type:"string" enum:"PackageVersionStatus"` + // A prefix used to filter returned repositories. Only repositories with names + // that start with repositoryPrefix are returned. + RepositoryPrefix *string `location:"querystring" locationName:"repository-prefix" min:"2" type:"string"` } // String returns the string representation. @@ -8637,7 +11491,7 @@ type ListPackageVersionsInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionsInput) String() string { +func (s ListRepositoriesInDomainInput) String() string { return awsutil.Prettify(s) } @@ -8646,13 +11500,16 @@ func (s ListPackageVersionsInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionsInput) GoString() string { +func (s ListRepositoriesInDomainInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListPackageVersionsInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListPackageVersionsInput"} +func (s *ListRepositoriesInDomainInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListRepositoriesInDomainInput"} + if s.AdministratorAccount != nil && len(*s.AdministratorAccount) < 12 { + invalidParams.Add(request.NewErrParamMinLen("AdministratorAccount", 12)) + } if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -8662,29 +11519,14 @@ func (s *ListPackageVersionsInput) Validate() error { if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) } - if s.Format == nil { - invalidParams.Add(request.NewErrParamRequired("Format")) - } if s.MaxResults != nil && *s.MaxResults < 1 { invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.Namespace != nil && len(*s.Namespace) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) - } if s.NextToken != nil && len(*s.NextToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } - if s.Package == nil { - invalidParams.Add(request.NewErrParamRequired("Package")) - } - if s.Package != nil && len(*s.Package) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Package", 1)) - } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) - } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + if s.RepositoryPrefix != nil && len(*s.RepositoryPrefix) < 2 { + invalidParams.Add(request.NewErrParamMinLen("RepositoryPrefix", 2)) } if invalidParams.Len() > 0 { @@ -8693,108 +11535,161 @@ func (s *ListPackageVersionsInput) Validate() error { return nil } +// SetAdministratorAccount sets the AdministratorAccount field's value. +func (s *ListRepositoriesInDomainInput) SetAdministratorAccount(v string) *ListRepositoriesInDomainInput { + s.AdministratorAccount = &v + return s +} + // SetDomain sets the Domain field's value. -func (s *ListPackageVersionsInput) SetDomain(v string) *ListPackageVersionsInput { +func (s *ListRepositoriesInDomainInput) SetDomain(v string) *ListRepositoriesInDomainInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *ListPackageVersionsInput) SetDomainOwner(v string) *ListPackageVersionsInput { +func (s *ListRepositoriesInDomainInput) SetDomainOwner(v string) *ListRepositoriesInDomainInput { s.DomainOwner = &v return s } -// SetFormat sets the Format field's value. -func (s *ListPackageVersionsInput) SetFormat(v string) *ListPackageVersionsInput { - s.Format = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListRepositoriesInDomainInput) SetMaxResults(v int64) *ListRepositoriesInDomainInput { + s.MaxResults = &v return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListPackageVersionsInput) SetMaxResults(v int64) *ListPackageVersionsInput { - s.MaxResults = &v +// SetNextToken sets the NextToken field's value. +func (s *ListRepositoriesInDomainInput) SetNextToken(v string) *ListRepositoriesInDomainInput { + s.NextToken = &v return s } -// SetNamespace sets the Namespace field's value. -func (s *ListPackageVersionsInput) SetNamespace(v string) *ListPackageVersionsInput { - s.Namespace = &v +// SetRepositoryPrefix sets the RepositoryPrefix field's value. +func (s *ListRepositoriesInDomainInput) SetRepositoryPrefix(v string) *ListRepositoriesInDomainInput { + s.RepositoryPrefix = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListPackageVersionsInput) SetNextToken(v string) *ListPackageVersionsInput { - s.NextToken = &v - return s +type ListRepositoriesInDomainOutput struct { + _ struct{} `type:"structure"` + + // If there are additional results, this is the token for the next set of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` + + // The returned list of repositories. + Repositories []*RepositorySummary `locationName:"repositories" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListRepositoriesInDomainOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListRepositoriesInDomainOutput) GoString() string { + return s.String() +} + +// SetNextToken sets the NextToken field's value. +func (s *ListRepositoriesInDomainOutput) SetNextToken(v string) *ListRepositoriesInDomainOutput { + s.NextToken = &v + return s +} + +// SetRepositories sets the Repositories field's value. +func (s *ListRepositoriesInDomainOutput) SetRepositories(v []*RepositorySummary) *ListRepositoriesInDomainOutput { + s.Repositories = v + return s +} + +type ListRepositoriesInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The maximum number of results to return per page. + MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` + + // The token for the next set of results. Use the value returned in the previous + // response in the next request to retrieve the next set of results. + NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` + + // A prefix used to filter returned repositories. Only repositories with names + // that start with repositoryPrefix are returned. + RepositoryPrefix *string `location:"querystring" locationName:"repository-prefix" min:"2" type:"string"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListRepositoriesInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListRepositoriesInput) GoString() string { + return s.String() } -// SetOriginType sets the OriginType field's value. -func (s *ListPackageVersionsInput) SetOriginType(v string) *ListPackageVersionsInput { - s.OriginType = &v - return s -} +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListRepositoriesInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListRepositoriesInput"} + if s.MaxResults != nil && *s.MaxResults < 1 { + invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) + } + if s.NextToken != nil && len(*s.NextToken) < 1 { + invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) + } + if s.RepositoryPrefix != nil && len(*s.RepositoryPrefix) < 2 { + invalidParams.Add(request.NewErrParamMinLen("RepositoryPrefix", 2)) + } -// SetPackage sets the Package field's value. -func (s *ListPackageVersionsInput) SetPackage(v string) *ListPackageVersionsInput { - s.Package = &v - return s + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetRepository sets the Repository field's value. -func (s *ListPackageVersionsInput) SetRepository(v string) *ListPackageVersionsInput { - s.Repository = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListRepositoriesInput) SetMaxResults(v int64) *ListRepositoriesInput { + s.MaxResults = &v return s } -// SetSortBy sets the SortBy field's value. -func (s *ListPackageVersionsInput) SetSortBy(v string) *ListPackageVersionsInput { - s.SortBy = &v +// SetNextToken sets the NextToken field's value. +func (s *ListRepositoriesInput) SetNextToken(v string) *ListRepositoriesInput { + s.NextToken = &v return s } -// SetStatus sets the Status field's value. -func (s *ListPackageVersionsInput) SetStatus(v string) *ListPackageVersionsInput { - s.Status = &v +// SetRepositoryPrefix sets the RepositoryPrefix field's value. +func (s *ListRepositoriesInput) SetRepositoryPrefix(v string) *ListRepositoriesInput { + s.RepositoryPrefix = &v return s } -type ListPackageVersionsOutput struct { +type ListRepositoriesOutput struct { _ struct{} `type:"structure"` - // The default package version to display. This depends on the package format: - // - // * For Maven and PyPI packages, it's the most recently published package - // version. - // - // * For npm packages, it's the version referenced by the latest tag. If - // the latest tag is not set, it's the most recently published package version. - DefaultDisplayVersion *string `locationName:"defaultDisplayVersion" min:"1" type:"string"` - - // A format of the package. - Format *string `locationName:"format" type:"string" enum:"PackageFormat"` - - // The namespace of the package that contains the requested package versions. - // The package component that specifies its namespace depends on its type. For - // example: - // - // * The namespace of a Maven package is its groupId. - // - // * The namespace of an npm package is its scope. - // - // * Python and NuGet packages do not contain a corresponding component, - // packages of those formats do not have a namespace. - Namespace *string `locationName:"namespace" min:"1" type:"string"` - // If there are additional results, this is the token for the next set of results. NextToken *string `locationName:"nextToken" min:"1" type:"string"` - // The name of the package. - Package *string `locationName:"package" min:"1" type:"string"` - - // The returned list of PackageVersionSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionSummary.html) + // The returned list of RepositorySummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_RepositorySummary.html) // objects. - Versions []*PackageVersionSummary `locationName:"versions" type:"list"` + Repositories []*RepositorySummary `locationName:"repositories" type:"list"` } // String returns the string representation. @@ -8802,7 +11697,7 @@ type ListPackageVersionsOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionsOutput) String() string { +func (s ListRepositoriesOutput) String() string { return awsutil.Prettify(s) } @@ -8811,51 +11706,27 @@ func (s ListPackageVersionsOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackageVersionsOutput) GoString() string { +func (s ListRepositoriesOutput) GoString() string { return s.String() } -// SetDefaultDisplayVersion sets the DefaultDisplayVersion field's value. -func (s *ListPackageVersionsOutput) SetDefaultDisplayVersion(v string) *ListPackageVersionsOutput { - s.DefaultDisplayVersion = &v - return s -} - -// SetFormat sets the Format field's value. -func (s *ListPackageVersionsOutput) SetFormat(v string) *ListPackageVersionsOutput { - s.Format = &v - return s -} - -// SetNamespace sets the Namespace field's value. -func (s *ListPackageVersionsOutput) SetNamespace(v string) *ListPackageVersionsOutput { - s.Namespace = &v - return s -} - // SetNextToken sets the NextToken field's value. -func (s *ListPackageVersionsOutput) SetNextToken(v string) *ListPackageVersionsOutput { +func (s *ListRepositoriesOutput) SetNextToken(v string) *ListRepositoriesOutput { s.NextToken = &v return s } -// SetPackage sets the Package field's value. -func (s *ListPackageVersionsOutput) SetPackage(v string) *ListPackageVersionsOutput { - s.Package = &v - return s -} - -// SetVersions sets the Versions field's value. -func (s *ListPackageVersionsOutput) SetVersions(v []*PackageVersionSummary) *ListPackageVersionsOutput { - s.Versions = v +// SetRepositories sets the Repositories field's value. +func (s *ListRepositoriesOutput) SetRepositories(v []*RepositorySummary) *ListRepositoriesOutput { + s.Repositories = v return s } -type ListPackagesInput struct { +type ListSubPackageGroupsInput struct { _ struct{} `type:"structure" nopayload:"true"` - // The name of the domain that contains the repository that contains the requested - // packages. + // The name of the domain which contains the package group from which to list + // sub package groups. // // Domain is a required field Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` @@ -8864,52 +11735,17 @@ type ListPackagesInput struct { // the domain. It does not include dashes or spaces. DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` - // The format used to filter requested packages. Only packages from the provided - // format will be returned. - Format *string `location:"querystring" locationName:"format" type:"string" enum:"PackageFormat"` - // The maximum number of results to return per page. MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` - // The namespace prefix used to filter requested packages. Only packages with - // a namespace that starts with the provided string value are returned. Note - // that although this option is called --namespace and not --namespace-prefix, - // it has prefix-matching behavior. - // - // Each package format uses namespace as follows: - // - // * The namespace of a Maven package is its groupId. - // - // * The namespace of an npm package is its scope. - // - // * Python and NuGet packages do not contain a corresponding component, - // packages of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. - Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` - // The token for the next set of results. Use the value returned in the previous // response in the next request to retrieve the next set of results. NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` - // A prefix used to filter requested packages. Only packages with names that - // start with packagePrefix are returned. - PackagePrefix *string `location:"querystring" locationName:"package-prefix" min:"1" type:"string"` - - // The value of the Publish package origin control restriction used to filter - // requested packages. Only packages with the provided restriction are returned. - // For more information, see PackageOriginRestrictions (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageOriginRestrictions.html). - Publish *string `location:"querystring" locationName:"publish" type:"string" enum:"AllowPublish"` - - // The name of the repository that contains the requested packages. + // The pattern of the package group from which to list sub package groups. // - // Repository is a required field - Repository *string `location:"querystring" locationName:"repository" min:"2" type:"string" required:"true"` - - // The value of the Upstream package origin control restriction used to filter - // requested packages. Only packages with the provided restriction are returned. - // For more information, see PackageOriginRestrictions (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageOriginRestrictions.html). - Upstream *string `location:"querystring" locationName:"upstream" type:"string" enum:"AllowUpstream"` + // PackageGroup is a required field + PackageGroup *string `location:"querystring" locationName:"package-group" min:"2" type:"string" required:"true"` } // String returns the string representation. @@ -8917,7 +11753,7 @@ type ListPackagesInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackagesInput) String() string { +func (s ListSubPackageGroupsInput) String() string { return awsutil.Prettify(s) } @@ -8926,13 +11762,13 @@ func (s ListPackagesInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackagesInput) GoString() string { +func (s ListSubPackageGroupsInput) GoString() string { return s.String() } // Validate inspects the fields of the type to determine if they are valid. -func (s *ListPackagesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListPackagesInput"} +func (s *ListSubPackageGroupsInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListSubPackageGroupsInput"} if s.Domain == nil { invalidParams.Add(request.NewErrParamRequired("Domain")) } @@ -8945,20 +11781,14 @@ func (s *ListPackagesInput) Validate() error { if s.MaxResults != nil && *s.MaxResults < 1 { invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) } - if s.Namespace != nil && len(*s.Namespace) < 1 { - invalidParams.Add(request.NewErrParamMinLen("Namespace", 1)) - } if s.NextToken != nil && len(*s.NextToken) < 1 { invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) } - if s.PackagePrefix != nil && len(*s.PackagePrefix) < 1 { - invalidParams.Add(request.NewErrParamMinLen("PackagePrefix", 1)) - } - if s.Repository == nil { - invalidParams.Add(request.NewErrParamRequired("Repository")) + if s.PackageGroup == nil { + invalidParams.Add(request.NewErrParamRequired("PackageGroup")) } - if s.Repository != nil && len(*s.Repository) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Repository", 2)) + if s.PackageGroup != nil && len(*s.PackageGroup) < 2 { + invalidParams.Add(request.NewErrParamMinLen("PackageGroup", 2)) } if invalidParams.Len() > 0 { @@ -8968,74 +11798,129 @@ func (s *ListPackagesInput) Validate() error { } // SetDomain sets the Domain field's value. -func (s *ListPackagesInput) SetDomain(v string) *ListPackagesInput { +func (s *ListSubPackageGroupsInput) SetDomain(v string) *ListSubPackageGroupsInput { s.Domain = &v return s } // SetDomainOwner sets the DomainOwner field's value. -func (s *ListPackagesInput) SetDomainOwner(v string) *ListPackagesInput { +func (s *ListSubPackageGroupsInput) SetDomainOwner(v string) *ListSubPackageGroupsInput { s.DomainOwner = &v return s } -// SetFormat sets the Format field's value. -func (s *ListPackagesInput) SetFormat(v string) *ListPackagesInput { - s.Format = &v +// SetMaxResults sets the MaxResults field's value. +func (s *ListSubPackageGroupsInput) SetMaxResults(v int64) *ListSubPackageGroupsInput { + s.MaxResults = &v return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListPackagesInput) SetMaxResults(v int64) *ListPackagesInput { - s.MaxResults = &v +// SetNextToken sets the NextToken field's value. +func (s *ListSubPackageGroupsInput) SetNextToken(v string) *ListSubPackageGroupsInput { + s.NextToken = &v return s } -// SetNamespace sets the Namespace field's value. -func (s *ListPackagesInput) SetNamespace(v string) *ListPackagesInput { - s.Namespace = &v +// SetPackageGroup sets the PackageGroup field's value. +func (s *ListSubPackageGroupsInput) SetPackageGroup(v string) *ListSubPackageGroupsInput { + s.PackageGroup = &v return s } +type ListSubPackageGroupsOutput struct { + _ struct{} `type:"structure"` + + // If there are additional results, this is the token for the next set of results. + NextToken *string `locationName:"nextToken" min:"1" type:"string"` + + // A list of sub package groups for the requested package group. + PackageGroups []*PackageGroupSummary `locationName:"packageGroups" type:"list"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListSubPackageGroupsOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListSubPackageGroupsOutput) GoString() string { + return s.String() +} + // SetNextToken sets the NextToken field's value. -func (s *ListPackagesInput) SetNextToken(v string) *ListPackagesInput { +func (s *ListSubPackageGroupsOutput) SetNextToken(v string) *ListSubPackageGroupsOutput { s.NextToken = &v return s } -// SetPackagePrefix sets the PackagePrefix field's value. -func (s *ListPackagesInput) SetPackagePrefix(v string) *ListPackagesInput { - s.PackagePrefix = &v +// SetPackageGroups sets the PackageGroups field's value. +func (s *ListSubPackageGroupsOutput) SetPackageGroups(v []*PackageGroupSummary) *ListSubPackageGroupsOutput { + s.PackageGroups = v return s } -// SetPublish sets the Publish field's value. -func (s *ListPackagesInput) SetPublish(v string) *ListPackagesInput { - s.Publish = &v - return s +type ListTagsForResourceInput struct { + _ struct{} `type:"structure" nopayload:"true"` + + // The Amazon Resource Name (ARN) of the resource to get tags for. + // + // ResourceArn is a required field + ResourceArn *string `location:"querystring" locationName:"resourceArn" min:"1" type:"string" required:"true"` } -// SetRepository sets the Repository field's value. -func (s *ListPackagesInput) SetRepository(v string) *ListPackagesInput { - s.Repository = &v - return s +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListTagsForResourceInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s ListTagsForResourceInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *ListTagsForResourceInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} + if s.ResourceArn == nil { + invalidParams.Add(request.NewErrParamRequired("ResourceArn")) + } + if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { + invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil } -// SetUpstream sets the Upstream field's value. -func (s *ListPackagesInput) SetUpstream(v string) *ListPackagesInput { - s.Upstream = &v +// SetResourceArn sets the ResourceArn field's value. +func (s *ListTagsForResourceInput) SetResourceArn(v string) *ListTagsForResourceInput { + s.ResourceArn = &v return s } -type ListPackagesOutput struct { +type ListTagsForResourceOutput struct { _ struct{} `type:"structure"` - // If there are additional results, this is the token for the next set of results. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` - - // The list of returned PackageSummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageSummary.html) - // objects. - Packages []*PackageSummary `locationName:"packages" type:"list"` + // A list of tag key and value pairs associated with the specified resource. + Tags []*Tag `locationName:"tags" type:"list"` } // String returns the string representation. @@ -9043,7 +11928,7 @@ type ListPackagesOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackagesOutput) String() string { +func (s ListTagsForResourceOutput) String() string { return awsutil.Prettify(s) } @@ -9052,48 +11937,55 @@ func (s ListPackagesOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListPackagesOutput) GoString() string { +func (s ListTagsForResourceOutput) GoString() string { return s.String() } -// SetNextToken sets the NextToken field's value. -func (s *ListPackagesOutput) SetNextToken(v string) *ListPackagesOutput { - s.NextToken = &v - return s -} - -// SetPackages sets the Packages field's value. -func (s *ListPackagesOutput) SetPackages(v []*PackageSummary) *ListPackagesOutput { - s.Packages = v +// SetTags sets the Tags field's value. +func (s *ListTagsForResourceOutput) SetTags(v []*Tag) *ListTagsForResourceOutput { + s.Tags = v return s } -type ListRepositoriesInDomainInput struct { - _ struct{} `type:"structure" nopayload:"true"` - - // Filter the list of repositories to only include those that are managed by - // the Amazon Web Services account ID. - AdministratorAccount *string `location:"querystring" locationName:"administrator-account" min:"12" type:"string"` +// Details about a package dependency. +type PackageDependency struct { + _ struct{} `type:"structure"` - // The name of the domain that contains the returned list of repositories. + // The type of a package dependency. The possible values depend on the package + // type. // - // Domain is a required field - Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` - - // The 12-digit account number of the Amazon Web Services account that owns - // the domain. It does not include dashes or spaces. - DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + // * npm: regular, dev, peer, optional + // + // * maven: optional, parent, compile, runtime, test, system, provided. Note + // that parent is not a regular Maven dependency type; instead this is extracted + // from the element if one is defined in the package version's POM + // file. + // + // * nuget: The dependencyType field is never set for NuGet packages. + // + // * pypi: Requires-Dist + DependencyType *string `locationName:"dependencyType" type:"string"` - // The maximum number of results to return per page. - MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` + // The namespace of the package that this package depends on. The package component + // that specifies its namespace depends on its type. For example: + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `locationName:"namespace" min:"1" type:"string"` - // The token for the next set of results. Use the value returned in the previous - // response in the next request to retrieve the next set of results. - NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` + // The name of the package that this package depends on. + Package *string `locationName:"package" min:"1" type:"string"` - // A prefix used to filter returned repositories. Only repositories with names - // that start with repositoryPrefix are returned. - RepositoryPrefix *string `location:"querystring" locationName:"repository-prefix" min:"2" type:"string"` + // The required version, or version range, of the package that this package + // depends on. The version format is specific to the package type. For example, + // the following are possible valid required versions: 1.2.3, ^2.3.4, or 4.x. + VersionRequirement *string `locationName:"versionRequirement" type:"string"` } // String returns the string representation. @@ -9101,7 +11993,7 @@ type ListRepositoriesInDomainInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListRepositoriesInDomainInput) String() string { +func (s PackageDependency) String() string { return awsutil.Prettify(s) } @@ -9110,85 +12002,113 @@ func (s ListRepositoriesInDomainInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListRepositoriesInDomainInput) GoString() string { +func (s PackageDependency) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListRepositoriesInDomainInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListRepositoriesInDomainInput"} - if s.AdministratorAccount != nil && len(*s.AdministratorAccount) < 12 { - invalidParams.Add(request.NewErrParamMinLen("AdministratorAccount", 12)) - } - if s.Domain == nil { - invalidParams.Add(request.NewErrParamRequired("Domain")) - } - if s.Domain != nil && len(*s.Domain) < 2 { - invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) - } - if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { - invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) - } - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) - } - if s.RepositoryPrefix != nil && len(*s.RepositoryPrefix) < 2 { - invalidParams.Add(request.NewErrParamMinLen("RepositoryPrefix", 2)) - } +// SetDependencyType sets the DependencyType field's value. +func (s *PackageDependency) SetDependencyType(v string) *PackageDependency { + s.DependencyType = &v + return s +} - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetNamespace sets the Namespace field's value. +func (s *PackageDependency) SetNamespace(v string) *PackageDependency { + s.Namespace = &v + return s } -// SetAdministratorAccount sets the AdministratorAccount field's value. -func (s *ListRepositoriesInDomainInput) SetAdministratorAccount(v string) *ListRepositoriesInDomainInput { - s.AdministratorAccount = &v +// SetPackage sets the Package field's value. +func (s *PackageDependency) SetPackage(v string) *PackageDependency { + s.Package = &v return s } -// SetDomain sets the Domain field's value. -func (s *ListRepositoriesInDomainInput) SetDomain(v string) *ListRepositoriesInDomainInput { - s.Domain = &v +// SetVersionRequirement sets the VersionRequirement field's value. +func (s *PackageDependency) SetVersionRequirement(v string) *PackageDependency { + s.VersionRequirement = &v return s } -// SetDomainOwner sets the DomainOwner field's value. -func (s *ListRepositoriesInDomainInput) SetDomainOwner(v string) *ListRepositoriesInDomainInput { - s.DomainOwner = &v +// Details about a package. +type PackageDescription struct { + _ struct{} `type:"structure"` + + // A format that specifies the type of the package. + Format *string `locationName:"format" type:"string" enum:"PackageFormat"` + + // The name of the package. + Name *string `locationName:"name" min:"1" type:"string"` + + // The namespace of the package. The package component that specifies its namespace + // depends on its type. For example: + // + // * The namespace of a Maven package version is its groupId. + // + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. + Namespace *string `locationName:"namespace" min:"1" type:"string"` + + // The package origin configuration for the package. + OriginConfiguration *PackageOriginConfiguration `locationName:"originConfiguration" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s PackageDescription) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s PackageDescription) GoString() string { + return s.String() +} + +// SetFormat sets the Format field's value. +func (s *PackageDescription) SetFormat(v string) *PackageDescription { + s.Format = &v return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListRepositoriesInDomainInput) SetMaxResults(v int64) *ListRepositoriesInDomainInput { - s.MaxResults = &v +// SetName sets the Name field's value. +func (s *PackageDescription) SetName(v string) *PackageDescription { + s.Name = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListRepositoriesInDomainInput) SetNextToken(v string) *ListRepositoriesInDomainInput { - s.NextToken = &v +// SetNamespace sets the Namespace field's value. +func (s *PackageDescription) SetNamespace(v string) *PackageDescription { + s.Namespace = &v return s } -// SetRepositoryPrefix sets the RepositoryPrefix field's value. -func (s *ListRepositoriesInDomainInput) SetRepositoryPrefix(v string) *ListRepositoriesInDomainInput { - s.RepositoryPrefix = &v +// SetOriginConfiguration sets the OriginConfiguration field's value. +func (s *PackageDescription) SetOriginConfiguration(v *PackageOriginConfiguration) *PackageDescription { + s.OriginConfiguration = v return s } -type ListRepositoriesInDomainOutput struct { +// Details about an allowed repository for a package group, including its name +// and origin configuration. +type PackageGroupAllowedRepository struct { _ struct{} `type:"structure"` - // If there are additional results, this is the token for the next set of results. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` + // The origin configuration restriction type of the allowed repository. + OriginRestrictionType *string `locationName:"originRestrictionType" type:"string" enum:"PackageGroupOriginRestrictionType"` - // The returned list of repositories. - Repositories []*RepositorySummary `locationName:"repositories" type:"list"` + // The name of the allowed repository. + RepositoryName *string `locationName:"repositoryName" min:"2" type:"string"` } // String returns the string representation. @@ -9196,7 +12116,7 @@ type ListRepositoriesInDomainOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListRepositoriesInDomainOutput) String() string { +func (s PackageGroupAllowedRepository) String() string { return awsutil.Prettify(s) } @@ -9205,35 +12125,68 @@ func (s ListRepositoriesInDomainOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListRepositoriesInDomainOutput) GoString() string { +func (s PackageGroupAllowedRepository) GoString() string { return s.String() } -// SetNextToken sets the NextToken field's value. -func (s *ListRepositoriesInDomainOutput) SetNextToken(v string) *ListRepositoriesInDomainOutput { - s.NextToken = &v +// Validate inspects the fields of the type to determine if they are valid. +func (s *PackageGroupAllowedRepository) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "PackageGroupAllowedRepository"} + if s.RepositoryName != nil && len(*s.RepositoryName) < 2 { + invalidParams.Add(request.NewErrParamMinLen("RepositoryName", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetOriginRestrictionType sets the OriginRestrictionType field's value. +func (s *PackageGroupAllowedRepository) SetOriginRestrictionType(v string) *PackageGroupAllowedRepository { + s.OriginRestrictionType = &v return s } -// SetRepositories sets the Repositories field's value. -func (s *ListRepositoriesInDomainOutput) SetRepositories(v []*RepositorySummary) *ListRepositoriesInDomainOutput { - s.Repositories = v +// SetRepositoryName sets the RepositoryName field's value. +func (s *PackageGroupAllowedRepository) SetRepositoryName(v string) *PackageGroupAllowedRepository { + s.RepositoryName = &v return s } -type ListRepositoriesInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// The description of the package group. +type PackageGroupDescription struct { + _ struct{} `type:"structure"` - // The maximum number of results to return per page. - MaxResults *int64 `location:"querystring" locationName:"max-results" min:"1" type:"integer"` + // The ARN of the package group. + Arn *string `locationName:"arn" min:"1" type:"string"` - // The token for the next set of results. Use the value returned in the previous - // response in the next request to retrieve the next set of results. - NextToken *string `location:"querystring" locationName:"next-token" min:"1" type:"string"` + // The contact information of the package group. + ContactInfo *string `locationName:"contactInfo" type:"string"` + + // A timestamp that represents the date and time the package group was created. + CreatedTime *time.Time `locationName:"createdTime" type:"timestamp"` + + // The description of the package group. + Description *string `locationName:"description" type:"string"` + + // The name of the domain that contains the package group. + DomainName *string `locationName:"domainName" min:"2" type:"string"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `locationName:"domainOwner" min:"12" type:"string"` - // A prefix used to filter returned repositories. Only repositories with names - // that start with repositoryPrefix are returned. - RepositoryPrefix *string `location:"querystring" locationName:"repository-prefix" min:"2" type:"string"` + // The package group origin configuration that determines how package versions + // can enter repositories. + OriginConfiguration *PackageGroupOriginConfiguration `locationName:"originConfiguration" type:"structure"` + + // The direct parent package group of the package group. + Parent *PackageGroupReference `locationName:"parent" type:"structure"` + + // The pattern of the package group. The pattern determines which packages are + // associated with the package group. + Pattern *string `locationName:"pattern" min:"2" type:"string"` } // String returns the string representation. @@ -9241,7 +12194,7 @@ type ListRepositoriesInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListRepositoriesInput) String() string { +func (s PackageGroupDescription) String() string { return awsutil.Prettify(s) } @@ -9250,95 +12203,72 @@ func (s ListRepositoriesInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListRepositoriesInput) GoString() string { +func (s PackageGroupDescription) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListRepositoriesInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListRepositoriesInput"} - if s.MaxResults != nil && *s.MaxResults < 1 { - invalidParams.Add(request.NewErrParamMinValue("MaxResults", 1)) - } - if s.NextToken != nil && len(*s.NextToken) < 1 { - invalidParams.Add(request.NewErrParamMinLen("NextToken", 1)) - } - if s.RepositoryPrefix != nil && len(*s.RepositoryPrefix) < 2 { - invalidParams.Add(request.NewErrParamMinLen("RepositoryPrefix", 2)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil +// SetArn sets the Arn field's value. +func (s *PackageGroupDescription) SetArn(v string) *PackageGroupDescription { + s.Arn = &v + return s } -// SetMaxResults sets the MaxResults field's value. -func (s *ListRepositoriesInput) SetMaxResults(v int64) *ListRepositoriesInput { - s.MaxResults = &v +// SetContactInfo sets the ContactInfo field's value. +func (s *PackageGroupDescription) SetContactInfo(v string) *PackageGroupDescription { + s.ContactInfo = &v return s } -// SetNextToken sets the NextToken field's value. -func (s *ListRepositoriesInput) SetNextToken(v string) *ListRepositoriesInput { - s.NextToken = &v +// SetCreatedTime sets the CreatedTime field's value. +func (s *PackageGroupDescription) SetCreatedTime(v time.Time) *PackageGroupDescription { + s.CreatedTime = &v return s } -// SetRepositoryPrefix sets the RepositoryPrefix field's value. -func (s *ListRepositoriesInput) SetRepositoryPrefix(v string) *ListRepositoriesInput { - s.RepositoryPrefix = &v +// SetDescription sets the Description field's value. +func (s *PackageGroupDescription) SetDescription(v string) *PackageGroupDescription { + s.Description = &v return s } -type ListRepositoriesOutput struct { - _ struct{} `type:"structure"` - - // If there are additional results, this is the token for the next set of results. - NextToken *string `locationName:"nextToken" min:"1" type:"string"` - - // The returned list of RepositorySummary (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_RepositorySummary.html) - // objects. - Repositories []*RepositorySummary `locationName:"repositories" type:"list"` +// SetDomainName sets the DomainName field's value. +func (s *PackageGroupDescription) SetDomainName(v string) *PackageGroupDescription { + s.DomainName = &v + return s } -// String returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s ListRepositoriesOutput) String() string { - return awsutil.Prettify(s) +// SetDomainOwner sets the DomainOwner field's value. +func (s *PackageGroupDescription) SetDomainOwner(v string) *PackageGroupDescription { + s.DomainOwner = &v + return s } -// GoString returns the string representation. -// -// API parameter values that are decorated as "sensitive" in the API will not -// be included in the string output. The member name will be present, but the -// value will be replaced with "sensitive". -func (s ListRepositoriesOutput) GoString() string { - return s.String() +// SetOriginConfiguration sets the OriginConfiguration field's value. +func (s *PackageGroupDescription) SetOriginConfiguration(v *PackageGroupOriginConfiguration) *PackageGroupDescription { + s.OriginConfiguration = v + return s } -// SetNextToken sets the NextToken field's value. -func (s *ListRepositoriesOutput) SetNextToken(v string) *ListRepositoriesOutput { - s.NextToken = &v +// SetParent sets the Parent field's value. +func (s *PackageGroupDescription) SetParent(v *PackageGroupReference) *PackageGroupDescription { + s.Parent = v return s } -// SetRepositories sets the Repositories field's value. -func (s *ListRepositoriesOutput) SetRepositories(v []*RepositorySummary) *ListRepositoriesOutput { - s.Repositories = v +// SetPattern sets the Pattern field's value. +func (s *PackageGroupDescription) SetPattern(v string) *PackageGroupDescription { + s.Pattern = &v return s } -type ListTagsForResourceInput struct { - _ struct{} `type:"structure" nopayload:"true"` +// The package group origin configuration that determines how package versions +// can enter repositories. +type PackageGroupOriginConfiguration struct { + _ struct{} `type:"structure"` - // The Amazon Resource Name (ARN) of the resource to get tags for. - // - // ResourceArn is a required field - ResourceArn *string `location:"querystring" locationName:"resourceArn" min:"1" type:"string" required:"true"` + // The origin configuration settings that determine how package versions can + // enter repositories. + Restrictions map[string]*PackageGroupOriginRestriction `locationName:"restrictions" type:"map"` } // String returns the string representation. @@ -9346,7 +12276,7 @@ type ListTagsForResourceInput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListTagsForResourceInput) String() string { +func (s PackageGroupOriginConfiguration) String() string { return awsutil.Prettify(s) } @@ -9355,37 +12285,41 @@ func (s ListTagsForResourceInput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListTagsForResourceInput) GoString() string { +func (s PackageGroupOriginConfiguration) GoString() string { return s.String() } -// Validate inspects the fields of the type to determine if they are valid. -func (s *ListTagsForResourceInput) Validate() error { - invalidParams := request.ErrInvalidParams{Context: "ListTagsForResourceInput"} - if s.ResourceArn == nil { - invalidParams.Add(request.NewErrParamRequired("ResourceArn")) - } - if s.ResourceArn != nil && len(*s.ResourceArn) < 1 { - invalidParams.Add(request.NewErrParamMinLen("ResourceArn", 1)) - } - - if invalidParams.Len() > 0 { - return invalidParams - } - return nil -} - -// SetResourceArn sets the ResourceArn field's value. -func (s *ListTagsForResourceInput) SetResourceArn(v string) *ListTagsForResourceInput { - s.ResourceArn = &v +// SetRestrictions sets the Restrictions field's value. +func (s *PackageGroupOriginConfiguration) SetRestrictions(v map[string]*PackageGroupOriginRestriction) *PackageGroupOriginConfiguration { + s.Restrictions = v return s } -type ListTagsForResourceOutput struct { +// Contains information about the configured restrictions of the origin controls +// of a package group. +type PackageGroupOriginRestriction struct { _ struct{} `type:"structure"` - // A list of tag key and value pairs associated with the specified resource. - Tags []*Tag `locationName:"tags" type:"list"` + // The effective package group origin restriction setting. If the value of mode + // is ALLOW, ALLOW_SPECIFIC_REPOSITORIES, or BLOCK, then the value of effectiveMode + // is the same. Otherwise, when the value of mode is INHERIT, then the value + // of effectiveMode is the value of mode of the first parent group which does + // not have a value of INHERIT. + EffectiveMode *string `locationName:"effectiveMode" type:"string" enum:"PackageGroupOriginRestrictionMode"` + + // The parent package group that the package group origin restrictions are inherited + // from. + InheritedFrom *PackageGroupReference `locationName:"inheritedFrom" type:"structure"` + + // The package group origin restriction setting. If the value of mode is ALLOW, + // ALLOW_SPECIFIC_REPOSITORIES, or BLOCK, then the value of effectiveMode is + // the same. Otherwise, when the value is INHERIT, then the value of effectiveMode + // is the value of mode of the first parent group which does not have a value + // of INHERIT. + Mode *string `locationName:"mode" type:"string" enum:"PackageGroupOriginRestrictionMode"` + + // The number of repositories in the allowed repository list. + RepositoriesCount *int64 `locationName:"repositoriesCount" type:"long"` } // String returns the string representation. @@ -9393,7 +12327,7 @@ type ListTagsForResourceOutput struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListTagsForResourceOutput) String() string { +func (s PackageGroupOriginRestriction) String() string { return awsutil.Prettify(s) } @@ -9402,53 +12336,45 @@ func (s ListTagsForResourceOutput) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s ListTagsForResourceOutput) GoString() string { +func (s PackageGroupOriginRestriction) GoString() string { return s.String() } -// SetTags sets the Tags field's value. -func (s *ListTagsForResourceOutput) SetTags(v []*Tag) *ListTagsForResourceOutput { - s.Tags = v +// SetEffectiveMode sets the EffectiveMode field's value. +func (s *PackageGroupOriginRestriction) SetEffectiveMode(v string) *PackageGroupOriginRestriction { + s.EffectiveMode = &v return s } -// Details about a package dependency. -type PackageDependency struct { - _ struct{} `type:"structure"` +// SetInheritedFrom sets the InheritedFrom field's value. +func (s *PackageGroupOriginRestriction) SetInheritedFrom(v *PackageGroupReference) *PackageGroupOriginRestriction { + s.InheritedFrom = v + return s +} - // The type of a package dependency. The possible values depend on the package - // type. - // - // * npm: regular, dev, peer, optional - // - // * maven: optional, parent, compile, runtime, test, system, provided. Note - // that parent is not a regular Maven dependency type; instead this is extracted - // from the element if one is defined in the package version's POM - // file. - // - // * nuget: The dependencyType field is never set for NuGet packages. - // - // * pypi: Requires-Dist - DependencyType *string `locationName:"dependencyType" type:"string"` +// SetMode sets the Mode field's value. +func (s *PackageGroupOriginRestriction) SetMode(v string) *PackageGroupOriginRestriction { + s.Mode = &v + return s +} - // The namespace of the package that this package depends on. The package component - // that specifies its namespace depends on its type. For example: - // - // * The namespace of a Maven package is its groupId. - // - // * The namespace of an npm package is its scope. - // - // * Python and NuGet packages do not contain a corresponding component, - // packages of those formats do not have a namespace. - Namespace *string `locationName:"namespace" min:"1" type:"string"` +// SetRepositoriesCount sets the RepositoriesCount field's value. +func (s *PackageGroupOriginRestriction) SetRepositoriesCount(v int64) *PackageGroupOriginRestriction { + s.RepositoriesCount = &v + return s +} - // The name of the package that this package depends on. - Package *string `locationName:"package" min:"1" type:"string"` +// Information about the identifiers of a package group. +type PackageGroupReference struct { + _ struct{} `type:"structure"` - // The required version, or version range, of the package that this package - // depends on. The version format is specific to the package type. For example, - // the following are possible valid required versions: 1.2.3, ^2.3.4, or 4.x. - VersionRequirement *string `locationName:"versionRequirement" type:"string"` + // The ARN of the package group. + Arn *string `locationName:"arn" min:"1" type:"string"` + + // The pattern of the package group. The pattern determines which packages are + // associated with the package group, and is also the identifier of the package + // group. + Pattern *string `locationName:"pattern" min:"2" type:"string"` } // String returns the string representation. @@ -9456,7 +12382,7 @@ type PackageDependency struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PackageDependency) String() string { +func (s PackageGroupReference) String() string { return awsutil.Prettify(s) } @@ -9465,59 +12391,54 @@ func (s PackageDependency) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PackageDependency) GoString() string { +func (s PackageGroupReference) GoString() string { return s.String() } -// SetDependencyType sets the DependencyType field's value. -func (s *PackageDependency) SetDependencyType(v string) *PackageDependency { - s.DependencyType = &v +// SetArn sets the Arn field's value. +func (s *PackageGroupReference) SetArn(v string) *PackageGroupReference { + s.Arn = &v return s } -// SetNamespace sets the Namespace field's value. -func (s *PackageDependency) SetNamespace(v string) *PackageDependency { - s.Namespace = &v +// SetPattern sets the Pattern field's value. +func (s *PackageGroupReference) SetPattern(v string) *PackageGroupReference { + s.Pattern = &v return s } -// SetPackage sets the Package field's value. -func (s *PackageDependency) SetPackage(v string) *PackageDependency { - s.Package = &v - return s -} +// Details about a package group. +type PackageGroupSummary struct { + _ struct{} `type:"structure"` -// SetVersionRequirement sets the VersionRequirement field's value. -func (s *PackageDependency) SetVersionRequirement(v string) *PackageDependency { - s.VersionRequirement = &v - return s -} + // The ARN of the package group. + Arn *string `locationName:"arn" min:"1" type:"string"` -// Details about a package. -type PackageDescription struct { - _ struct{} `type:"structure"` + // The contact information of the package group. + ContactInfo *string `locationName:"contactInfo" type:"string"` - // A format that specifies the type of the package. - Format *string `locationName:"format" type:"string" enum:"PackageFormat"` + // A timestamp that represents the date and time the repository was created. + CreatedTime *time.Time `locationName:"createdTime" type:"timestamp"` - // The name of the package. - Name *string `locationName:"name" min:"1" type:"string"` + // The description of the package group. + Description *string `locationName:"description" type:"string"` - // The namespace of the package. The package component that specifies its namespace - // depends on its type. For example: - // - // * The namespace of a Maven package is its groupId. - // - // * The namespace of an npm package is its scope. - // - // * Python and NuGet packages do not contain a corresponding component, - // packages of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. - Namespace *string `locationName:"namespace" min:"1" type:"string"` + // The domain that contains the package group. + DomainName *string `locationName:"domainName" min:"2" type:"string"` - // The package origin configuration for the package. - OriginConfiguration *PackageOriginConfiguration `locationName:"originConfiguration" type:"structure"` + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `locationName:"domainOwner" min:"12" type:"string"` + + // Details about the package origin configuration of a package group. + OriginConfiguration *PackageGroupOriginConfiguration `locationName:"originConfiguration" type:"structure"` + + // The direct parent package group of the package group. + Parent *PackageGroupReference `locationName:"parent" type:"structure"` + + // The pattern of the package group. The pattern determines which packages are + // associated with the package group. + Pattern *string `locationName:"pattern" min:"2" type:"string"` } // String returns the string representation. @@ -9525,7 +12446,7 @@ type PackageDescription struct { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PackageDescription) String() string { +func (s PackageGroupSummary) String() string { return awsutil.Prettify(s) } @@ -9534,34 +12455,64 @@ func (s PackageDescription) String() string { // API parameter values that are decorated as "sensitive" in the API will not // be included in the string output. The member name will be present, but the // value will be replaced with "sensitive". -func (s PackageDescription) GoString() string { +func (s PackageGroupSummary) GoString() string { return s.String() } -// SetFormat sets the Format field's value. -func (s *PackageDescription) SetFormat(v string) *PackageDescription { - s.Format = &v +// SetArn sets the Arn field's value. +func (s *PackageGroupSummary) SetArn(v string) *PackageGroupSummary { + s.Arn = &v return s } -// SetName sets the Name field's value. -func (s *PackageDescription) SetName(v string) *PackageDescription { - s.Name = &v +// SetContactInfo sets the ContactInfo field's value. +func (s *PackageGroupSummary) SetContactInfo(v string) *PackageGroupSummary { + s.ContactInfo = &v return s } -// SetNamespace sets the Namespace field's value. -func (s *PackageDescription) SetNamespace(v string) *PackageDescription { - s.Namespace = &v +// SetCreatedTime sets the CreatedTime field's value. +func (s *PackageGroupSummary) SetCreatedTime(v time.Time) *PackageGroupSummary { + s.CreatedTime = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *PackageGroupSummary) SetDescription(v string) *PackageGroupSummary { + s.Description = &v + return s +} + +// SetDomainName sets the DomainName field's value. +func (s *PackageGroupSummary) SetDomainName(v string) *PackageGroupSummary { + s.DomainName = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *PackageGroupSummary) SetDomainOwner(v string) *PackageGroupSummary { + s.DomainOwner = &v return s } // SetOriginConfiguration sets the OriginConfiguration field's value. -func (s *PackageDescription) SetOriginConfiguration(v *PackageOriginConfiguration) *PackageDescription { +func (s *PackageGroupSummary) SetOriginConfiguration(v *PackageGroupOriginConfiguration) *PackageGroupSummary { s.OriginConfiguration = v return s } +// SetParent sets the Parent field's value. +func (s *PackageGroupSummary) SetParent(v *PackageGroupReference) *PackageGroupSummary { + s.Parent = v + return s +} + +// SetPattern sets the Pattern field's value. +func (s *PackageGroupSummary) SetPattern(v string) *PackageGroupSummary { + s.Pattern = &v + return s +} + // Details about the package origin configuration of a package. type PackageOriginConfiguration struct { _ struct{} `type:"structure"` @@ -9670,14 +12621,14 @@ type PackageSummary struct { // The namespace of the package. The package component that specifies its namespace // depends on its type. For example: // - // * The namespace of a Maven package is its groupId. - // - // * The namespace of an npm package is its scope. + // * The namespace of a Maven package version is its groupId. // - // * Python and NuGet packages do not contain a corresponding component, - // packages of those formats do not have a namespace. + // * The namespace of an npm or Swift package version is its scope. // // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. Namespace *string `locationName:"namespace" min:"1" type:"string"` // A PackageOriginConfiguration (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageOriginConfiguration.html) @@ -9751,17 +12702,17 @@ type PackageVersionDescription struct { // Information about licenses associated with the package version. Licenses []*LicenseInfo `locationName:"licenses" type:"list"` - // The namespace of the package version. The package version component that - // specifies its namespace depends on its type. For example: + // The namespace of the package version. The package component that specifies + // its namespace depends on its type. For example: // // * The namespace of a Maven package version is its groupId. // - // * The namespace of an npm package version is its scope. - // - // * Python and NuGet package versions do not contain a corresponding component, - // package versions of those formats do not have a namespace. + // * The namespace of an npm or Swift package version is its scope. // // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. Namespace *string `locationName:"namespace" min:"1" type:"string"` // A PackageVersionOrigin (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionOrigin.html) @@ -10503,14 +13454,14 @@ type PutPackageOriginConfigurationInput struct { // The namespace of the package to be updated. The package component that specifies // its namespace depends on its type. For example: // - // * The namespace of a Maven package is its groupId. - // - // * The namespace of an npm package is its scope. + // * The namespace of a Maven package version is its groupId. // - // * Python and NuGet packages do not contain a corresponding component, - // packages of those formats do not have a namespace. + // * The namespace of an npm or Swift package version is its scope. // // * The namespace of a generic package is its namespace. + // + // * Python and NuGet package versions do not contain a corresponding component, + // package versions of those formats do not have a namespace. Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` // The name of the package to be updated. @@ -11631,6 +14582,305 @@ func (s UntagResourceOutput) GoString() string { return s.String() } +type UpdatePackageGroupInput struct { + _ struct{} `type:"structure"` + + // Contact information which you want to update the requested package group + // with. + ContactInfo *string `locationName:"contactInfo" type:"string"` + + // The description you want to update the requested package group with. + Description *string `locationName:"description" type:"string"` + + // The name of the domain which contains the package group to be updated. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The pattern of the package group to be updated. + // + // PackageGroup is a required field + PackageGroup *string `locationName:"packageGroup" min:"2" type:"string" required:"true"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdatePackageGroupInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdatePackageGroupInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdatePackageGroupInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdatePackageGroupInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.PackageGroup == nil { + invalidParams.Add(request.NewErrParamRequired("PackageGroup")) + } + if s.PackageGroup != nil && len(*s.PackageGroup) < 2 { + invalidParams.Add(request.NewErrParamMinLen("PackageGroup", 2)) + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetContactInfo sets the ContactInfo field's value. +func (s *UpdatePackageGroupInput) SetContactInfo(v string) *UpdatePackageGroupInput { + s.ContactInfo = &v + return s +} + +// SetDescription sets the Description field's value. +func (s *UpdatePackageGroupInput) SetDescription(v string) *UpdatePackageGroupInput { + s.Description = &v + return s +} + +// SetDomain sets the Domain field's value. +func (s *UpdatePackageGroupInput) SetDomain(v string) *UpdatePackageGroupInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *UpdatePackageGroupInput) SetDomainOwner(v string) *UpdatePackageGroupInput { + s.DomainOwner = &v + return s +} + +// SetPackageGroup sets the PackageGroup field's value. +func (s *UpdatePackageGroupInput) SetPackageGroup(v string) *UpdatePackageGroupInput { + s.PackageGroup = &v + return s +} + +type UpdatePackageGroupOriginConfigurationInput struct { + _ struct{} `type:"structure"` + + // The repository name and restrictions to add to the allowed repository list + // of the specified package group. + AddAllowedRepositories []*PackageGroupAllowedRepository `locationName:"addAllowedRepositories" type:"list"` + + // The name of the domain which contains the package group for which to update + // the origin configuration. + // + // Domain is a required field + Domain *string `location:"querystring" locationName:"domain" min:"2" type:"string" required:"true"` + + // The 12-digit account number of the Amazon Web Services account that owns + // the domain. It does not include dashes or spaces. + DomainOwner *string `location:"querystring" locationName:"domain-owner" min:"12" type:"string"` + + // The pattern of the package group for which to update the origin configuration. + // + // PackageGroup is a required field + PackageGroup *string `location:"querystring" locationName:"package-group" min:"2" type:"string" required:"true"` + + // The repository name and restrictions to remove from the allowed repository + // list of the specified package group. + RemoveAllowedRepositories []*PackageGroupAllowedRepository `locationName:"removeAllowedRepositories" type:"list"` + + // The origin configuration settings that determine how package versions can + // enter repositories. + Restrictions map[string]*string `locationName:"restrictions" type:"map"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdatePackageGroupOriginConfigurationInput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdatePackageGroupOriginConfigurationInput) GoString() string { + return s.String() +} + +// Validate inspects the fields of the type to determine if they are valid. +func (s *UpdatePackageGroupOriginConfigurationInput) Validate() error { + invalidParams := request.ErrInvalidParams{Context: "UpdatePackageGroupOriginConfigurationInput"} + if s.Domain == nil { + invalidParams.Add(request.NewErrParamRequired("Domain")) + } + if s.Domain != nil && len(*s.Domain) < 2 { + invalidParams.Add(request.NewErrParamMinLen("Domain", 2)) + } + if s.DomainOwner != nil && len(*s.DomainOwner) < 12 { + invalidParams.Add(request.NewErrParamMinLen("DomainOwner", 12)) + } + if s.PackageGroup == nil { + invalidParams.Add(request.NewErrParamRequired("PackageGroup")) + } + if s.PackageGroup != nil && len(*s.PackageGroup) < 2 { + invalidParams.Add(request.NewErrParamMinLen("PackageGroup", 2)) + } + if s.AddAllowedRepositories != nil { + for i, v := range s.AddAllowedRepositories { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "AddAllowedRepositories", i), err.(request.ErrInvalidParams)) + } + } + } + if s.RemoveAllowedRepositories != nil { + for i, v := range s.RemoveAllowedRepositories { + if v == nil { + continue + } + if err := v.Validate(); err != nil { + invalidParams.AddNested(fmt.Sprintf("%s[%v]", "RemoveAllowedRepositories", i), err.(request.ErrInvalidParams)) + } + } + } + + if invalidParams.Len() > 0 { + return invalidParams + } + return nil +} + +// SetAddAllowedRepositories sets the AddAllowedRepositories field's value. +func (s *UpdatePackageGroupOriginConfigurationInput) SetAddAllowedRepositories(v []*PackageGroupAllowedRepository) *UpdatePackageGroupOriginConfigurationInput { + s.AddAllowedRepositories = v + return s +} + +// SetDomain sets the Domain field's value. +func (s *UpdatePackageGroupOriginConfigurationInput) SetDomain(v string) *UpdatePackageGroupOriginConfigurationInput { + s.Domain = &v + return s +} + +// SetDomainOwner sets the DomainOwner field's value. +func (s *UpdatePackageGroupOriginConfigurationInput) SetDomainOwner(v string) *UpdatePackageGroupOriginConfigurationInput { + s.DomainOwner = &v + return s +} + +// SetPackageGroup sets the PackageGroup field's value. +func (s *UpdatePackageGroupOriginConfigurationInput) SetPackageGroup(v string) *UpdatePackageGroupOriginConfigurationInput { + s.PackageGroup = &v + return s +} + +// SetRemoveAllowedRepositories sets the RemoveAllowedRepositories field's value. +func (s *UpdatePackageGroupOriginConfigurationInput) SetRemoveAllowedRepositories(v []*PackageGroupAllowedRepository) *UpdatePackageGroupOriginConfigurationInput { + s.RemoveAllowedRepositories = v + return s +} + +// SetRestrictions sets the Restrictions field's value. +func (s *UpdatePackageGroupOriginConfigurationInput) SetRestrictions(v map[string]*string) *UpdatePackageGroupOriginConfigurationInput { + s.Restrictions = v + return s +} + +type UpdatePackageGroupOriginConfigurationOutput struct { + _ struct{} `type:"structure"` + + // Information about the updated allowed repositories after processing the request. + AllowedRepositoryUpdates map[string]map[string][]*string `locationName:"allowedRepositoryUpdates" type:"map"` + + // The package group and information about it after processing the request. + PackageGroup *PackageGroupDescription `locationName:"packageGroup" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdatePackageGroupOriginConfigurationOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdatePackageGroupOriginConfigurationOutput) GoString() string { + return s.String() +} + +// SetAllowedRepositoryUpdates sets the AllowedRepositoryUpdates field's value. +func (s *UpdatePackageGroupOriginConfigurationOutput) SetAllowedRepositoryUpdates(v map[string]map[string][]*string) *UpdatePackageGroupOriginConfigurationOutput { + s.AllowedRepositoryUpdates = v + return s +} + +// SetPackageGroup sets the PackageGroup field's value. +func (s *UpdatePackageGroupOriginConfigurationOutput) SetPackageGroup(v *PackageGroupDescription) *UpdatePackageGroupOriginConfigurationOutput { + s.PackageGroup = v + return s +} + +type UpdatePackageGroupOutput struct { + _ struct{} `type:"structure"` + + // The package group and information about it after the request has been processed. + PackageGroup *PackageGroupDescription `locationName:"packageGroup" type:"structure"` +} + +// String returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdatePackageGroupOutput) String() string { + return awsutil.Prettify(s) +} + +// GoString returns the string representation. +// +// API parameter values that are decorated as "sensitive" in the API will not +// be included in the string output. The member name will be present, but the +// value will be replaced with "sensitive". +func (s UpdatePackageGroupOutput) GoString() string { + return s.String() +} + +// SetPackageGroup sets the PackageGroup field's value. +func (s *UpdatePackageGroupOutput) SetPackageGroup(v *PackageGroupDescription) *UpdatePackageGroupOutput { + s.PackageGroup = v + return s +} + type UpdatePackageVersionsStatusInput struct { _ struct{} `type:"structure"` @@ -11654,17 +14904,17 @@ type UpdatePackageVersionsStatusInput struct { // Format is a required field Format *string `location:"querystring" locationName:"format" type:"string" required:"true" enum:"PackageFormat"` - // The namespace of the package version to be updated. The package version component + // The namespace of the package version to be updated. The package component // that specifies its namespace depends on its type. For example: // // * The namespace of a Maven package version is its groupId. // - // * The namespace of an npm package version is its scope. + // * The namespace of an npm or Swift package version is its scope. + // + // * The namespace of a generic package is its namespace. // // * Python and NuGet package versions do not contain a corresponding component, // package versions of those formats do not have a namespace. - // - // * The namespace of a generic package is its namespace. Namespace *string `location:"querystring" locationName:"namespace" min:"1" type:"string"` // The name of the package with the version statuses to update. @@ -12266,6 +15516,82 @@ func PackageFormat_Values() []string { } } +const ( + // PackageGroupAllowedRepositoryUpdateTypeAdded is a PackageGroupAllowedRepositoryUpdateType enum value + PackageGroupAllowedRepositoryUpdateTypeAdded = "ADDED" + + // PackageGroupAllowedRepositoryUpdateTypeRemoved is a PackageGroupAllowedRepositoryUpdateType enum value + PackageGroupAllowedRepositoryUpdateTypeRemoved = "REMOVED" +) + +// PackageGroupAllowedRepositoryUpdateType_Values returns all elements of the PackageGroupAllowedRepositoryUpdateType enum +func PackageGroupAllowedRepositoryUpdateType_Values() []string { + return []string{ + PackageGroupAllowedRepositoryUpdateTypeAdded, + PackageGroupAllowedRepositoryUpdateTypeRemoved, + } +} + +const ( + // PackageGroupAssociationTypeStrong is a PackageGroupAssociationType enum value + PackageGroupAssociationTypeStrong = "STRONG" + + // PackageGroupAssociationTypeWeak is a PackageGroupAssociationType enum value + PackageGroupAssociationTypeWeak = "WEAK" +) + +// PackageGroupAssociationType_Values returns all elements of the PackageGroupAssociationType enum +func PackageGroupAssociationType_Values() []string { + return []string{ + PackageGroupAssociationTypeStrong, + PackageGroupAssociationTypeWeak, + } +} + +const ( + // PackageGroupOriginRestrictionModeAllow is a PackageGroupOriginRestrictionMode enum value + PackageGroupOriginRestrictionModeAllow = "ALLOW" + + // PackageGroupOriginRestrictionModeAllowSpecificRepositories is a PackageGroupOriginRestrictionMode enum value + PackageGroupOriginRestrictionModeAllowSpecificRepositories = "ALLOW_SPECIFIC_REPOSITORIES" + + // PackageGroupOriginRestrictionModeBlock is a PackageGroupOriginRestrictionMode enum value + PackageGroupOriginRestrictionModeBlock = "BLOCK" + + // PackageGroupOriginRestrictionModeInherit is a PackageGroupOriginRestrictionMode enum value + PackageGroupOriginRestrictionModeInherit = "INHERIT" +) + +// PackageGroupOriginRestrictionMode_Values returns all elements of the PackageGroupOriginRestrictionMode enum +func PackageGroupOriginRestrictionMode_Values() []string { + return []string{ + PackageGroupOriginRestrictionModeAllow, + PackageGroupOriginRestrictionModeAllowSpecificRepositories, + PackageGroupOriginRestrictionModeBlock, + PackageGroupOriginRestrictionModeInherit, + } +} + +const ( + // PackageGroupOriginRestrictionTypeExternalUpstream is a PackageGroupOriginRestrictionType enum value + PackageGroupOriginRestrictionTypeExternalUpstream = "EXTERNAL_UPSTREAM" + + // PackageGroupOriginRestrictionTypeInternalUpstream is a PackageGroupOriginRestrictionType enum value + PackageGroupOriginRestrictionTypeInternalUpstream = "INTERNAL_UPSTREAM" + + // PackageGroupOriginRestrictionTypePublish is a PackageGroupOriginRestrictionType enum value + PackageGroupOriginRestrictionTypePublish = "PUBLISH" +) + +// PackageGroupOriginRestrictionType_Values returns all elements of the PackageGroupOriginRestrictionType enum +func PackageGroupOriginRestrictionType_Values() []string { + return []string{ + PackageGroupOriginRestrictionTypeExternalUpstream, + PackageGroupOriginRestrictionTypeInternalUpstream, + PackageGroupOriginRestrictionTypePublish, + } +} + const ( // PackageVersionErrorCodeAlreadyExists is a PackageVersionErrorCode enum value PackageVersionErrorCodeAlreadyExists = "ALREADY_EXISTS" diff --git a/service/codeartifact/codeartifactiface/interface.go b/service/codeartifact/codeartifactiface/interface.go index 64600880d32..be46e3304d6 100644 --- a/service/codeartifact/codeartifactiface/interface.go +++ b/service/codeartifact/codeartifactiface/interface.go @@ -72,6 +72,10 @@ type CodeArtifactAPI interface { CreateDomainWithContext(aws.Context, *codeartifact.CreateDomainInput, ...request.Option) (*codeartifact.CreateDomainOutput, error) CreateDomainRequest(*codeartifact.CreateDomainInput) (*request.Request, *codeartifact.CreateDomainOutput) + CreatePackageGroup(*codeartifact.CreatePackageGroupInput) (*codeartifact.CreatePackageGroupOutput, error) + CreatePackageGroupWithContext(aws.Context, *codeartifact.CreatePackageGroupInput, ...request.Option) (*codeartifact.CreatePackageGroupOutput, error) + CreatePackageGroupRequest(*codeartifact.CreatePackageGroupInput) (*request.Request, *codeartifact.CreatePackageGroupOutput) + CreateRepository(*codeartifact.CreateRepositoryInput) (*codeartifact.CreateRepositoryOutput, error) CreateRepositoryWithContext(aws.Context, *codeartifact.CreateRepositoryInput, ...request.Option) (*codeartifact.CreateRepositoryOutput, error) CreateRepositoryRequest(*codeartifact.CreateRepositoryInput) (*request.Request, *codeartifact.CreateRepositoryOutput) @@ -88,6 +92,10 @@ type CodeArtifactAPI interface { DeletePackageWithContext(aws.Context, *codeartifact.DeletePackageInput, ...request.Option) (*codeartifact.DeletePackageOutput, error) DeletePackageRequest(*codeartifact.DeletePackageInput) (*request.Request, *codeartifact.DeletePackageOutput) + DeletePackageGroup(*codeartifact.DeletePackageGroupInput) (*codeartifact.DeletePackageGroupOutput, error) + DeletePackageGroupWithContext(aws.Context, *codeartifact.DeletePackageGroupInput, ...request.Option) (*codeartifact.DeletePackageGroupOutput, error) + DeletePackageGroupRequest(*codeartifact.DeletePackageGroupInput) (*request.Request, *codeartifact.DeletePackageGroupOutput) + DeletePackageVersions(*codeartifact.DeletePackageVersionsInput) (*codeartifact.DeletePackageVersionsOutput, error) DeletePackageVersionsWithContext(aws.Context, *codeartifact.DeletePackageVersionsInput, ...request.Option) (*codeartifact.DeletePackageVersionsOutput, error) DeletePackageVersionsRequest(*codeartifact.DeletePackageVersionsInput) (*request.Request, *codeartifact.DeletePackageVersionsOutput) @@ -108,6 +116,10 @@ type CodeArtifactAPI interface { DescribePackageWithContext(aws.Context, *codeartifact.DescribePackageInput, ...request.Option) (*codeartifact.DescribePackageOutput, error) DescribePackageRequest(*codeartifact.DescribePackageInput) (*request.Request, *codeartifact.DescribePackageOutput) + DescribePackageGroup(*codeartifact.DescribePackageGroupInput) (*codeartifact.DescribePackageGroupOutput, error) + DescribePackageGroupWithContext(aws.Context, *codeartifact.DescribePackageGroupInput, ...request.Option) (*codeartifact.DescribePackageGroupOutput, error) + DescribePackageGroupRequest(*codeartifact.DescribePackageGroupInput) (*request.Request, *codeartifact.DescribePackageGroupOutput) + DescribePackageVersion(*codeartifact.DescribePackageVersionInput) (*codeartifact.DescribePackageVersionOutput, error) DescribePackageVersionWithContext(aws.Context, *codeartifact.DescribePackageVersionInput, ...request.Option) (*codeartifact.DescribePackageVersionOutput, error) DescribePackageVersionRequest(*codeartifact.DescribePackageVersionInput) (*request.Request, *codeartifact.DescribePackageVersionOutput) @@ -124,6 +136,10 @@ type CodeArtifactAPI interface { DisposePackageVersionsWithContext(aws.Context, *codeartifact.DisposePackageVersionsInput, ...request.Option) (*codeartifact.DisposePackageVersionsOutput, error) DisposePackageVersionsRequest(*codeartifact.DisposePackageVersionsInput) (*request.Request, *codeartifact.DisposePackageVersionsOutput) + GetAssociatedPackageGroup(*codeartifact.GetAssociatedPackageGroupInput) (*codeartifact.GetAssociatedPackageGroupOutput, error) + GetAssociatedPackageGroupWithContext(aws.Context, *codeartifact.GetAssociatedPackageGroupInput, ...request.Option) (*codeartifact.GetAssociatedPackageGroupOutput, error) + GetAssociatedPackageGroupRequest(*codeartifact.GetAssociatedPackageGroupInput) (*request.Request, *codeartifact.GetAssociatedPackageGroupOutput) + GetAuthorizationToken(*codeartifact.GetAuthorizationTokenInput) (*codeartifact.GetAuthorizationTokenOutput, error) GetAuthorizationTokenWithContext(aws.Context, *codeartifact.GetAuthorizationTokenInput, ...request.Option) (*codeartifact.GetAuthorizationTokenOutput, error) GetAuthorizationTokenRequest(*codeartifact.GetAuthorizationTokenInput) (*request.Request, *codeartifact.GetAuthorizationTokenOutput) @@ -148,6 +164,20 @@ type CodeArtifactAPI interface { GetRepositoryPermissionsPolicyWithContext(aws.Context, *codeartifact.GetRepositoryPermissionsPolicyInput, ...request.Option) (*codeartifact.GetRepositoryPermissionsPolicyOutput, error) GetRepositoryPermissionsPolicyRequest(*codeartifact.GetRepositoryPermissionsPolicyInput) (*request.Request, *codeartifact.GetRepositoryPermissionsPolicyOutput) + ListAllowedRepositoriesForGroup(*codeartifact.ListAllowedRepositoriesForGroupInput) (*codeartifact.ListAllowedRepositoriesForGroupOutput, error) + ListAllowedRepositoriesForGroupWithContext(aws.Context, *codeartifact.ListAllowedRepositoriesForGroupInput, ...request.Option) (*codeartifact.ListAllowedRepositoriesForGroupOutput, error) + ListAllowedRepositoriesForGroupRequest(*codeartifact.ListAllowedRepositoriesForGroupInput) (*request.Request, *codeartifact.ListAllowedRepositoriesForGroupOutput) + + ListAllowedRepositoriesForGroupPages(*codeartifact.ListAllowedRepositoriesForGroupInput, func(*codeartifact.ListAllowedRepositoriesForGroupOutput, bool) bool) error + ListAllowedRepositoriesForGroupPagesWithContext(aws.Context, *codeartifact.ListAllowedRepositoriesForGroupInput, func(*codeartifact.ListAllowedRepositoriesForGroupOutput, bool) bool, ...request.Option) error + + ListAssociatedPackages(*codeartifact.ListAssociatedPackagesInput) (*codeartifact.ListAssociatedPackagesOutput, error) + ListAssociatedPackagesWithContext(aws.Context, *codeartifact.ListAssociatedPackagesInput, ...request.Option) (*codeartifact.ListAssociatedPackagesOutput, error) + ListAssociatedPackagesRequest(*codeartifact.ListAssociatedPackagesInput) (*request.Request, *codeartifact.ListAssociatedPackagesOutput) + + ListAssociatedPackagesPages(*codeartifact.ListAssociatedPackagesInput, func(*codeartifact.ListAssociatedPackagesOutput, bool) bool) error + ListAssociatedPackagesPagesWithContext(aws.Context, *codeartifact.ListAssociatedPackagesInput, func(*codeartifact.ListAssociatedPackagesOutput, bool) bool, ...request.Option) error + ListDomains(*codeartifact.ListDomainsInput) (*codeartifact.ListDomainsOutput, error) ListDomainsWithContext(aws.Context, *codeartifact.ListDomainsInput, ...request.Option) (*codeartifact.ListDomainsOutput, error) ListDomainsRequest(*codeartifact.ListDomainsInput) (*request.Request, *codeartifact.ListDomainsOutput) @@ -155,6 +185,13 @@ type CodeArtifactAPI interface { ListDomainsPages(*codeartifact.ListDomainsInput, func(*codeartifact.ListDomainsOutput, bool) bool) error ListDomainsPagesWithContext(aws.Context, *codeartifact.ListDomainsInput, func(*codeartifact.ListDomainsOutput, bool) bool, ...request.Option) error + ListPackageGroups(*codeartifact.ListPackageGroupsInput) (*codeartifact.ListPackageGroupsOutput, error) + ListPackageGroupsWithContext(aws.Context, *codeartifact.ListPackageGroupsInput, ...request.Option) (*codeartifact.ListPackageGroupsOutput, error) + ListPackageGroupsRequest(*codeartifact.ListPackageGroupsInput) (*request.Request, *codeartifact.ListPackageGroupsOutput) + + ListPackageGroupsPages(*codeartifact.ListPackageGroupsInput, func(*codeartifact.ListPackageGroupsOutput, bool) bool) error + ListPackageGroupsPagesWithContext(aws.Context, *codeartifact.ListPackageGroupsInput, func(*codeartifact.ListPackageGroupsOutput, bool) bool, ...request.Option) error + ListPackageVersionAssets(*codeartifact.ListPackageVersionAssetsInput) (*codeartifact.ListPackageVersionAssetsOutput, error) ListPackageVersionAssetsWithContext(aws.Context, *codeartifact.ListPackageVersionAssetsInput, ...request.Option) (*codeartifact.ListPackageVersionAssetsOutput, error) ListPackageVersionAssetsRequest(*codeartifact.ListPackageVersionAssetsInput) (*request.Request, *codeartifact.ListPackageVersionAssetsOutput) @@ -194,6 +231,13 @@ type CodeArtifactAPI interface { ListRepositoriesInDomainPages(*codeartifact.ListRepositoriesInDomainInput, func(*codeartifact.ListRepositoriesInDomainOutput, bool) bool) error ListRepositoriesInDomainPagesWithContext(aws.Context, *codeartifact.ListRepositoriesInDomainInput, func(*codeartifact.ListRepositoriesInDomainOutput, bool) bool, ...request.Option) error + ListSubPackageGroups(*codeartifact.ListSubPackageGroupsInput) (*codeartifact.ListSubPackageGroupsOutput, error) + ListSubPackageGroupsWithContext(aws.Context, *codeartifact.ListSubPackageGroupsInput, ...request.Option) (*codeartifact.ListSubPackageGroupsOutput, error) + ListSubPackageGroupsRequest(*codeartifact.ListSubPackageGroupsInput) (*request.Request, *codeartifact.ListSubPackageGroupsOutput) + + ListSubPackageGroupsPages(*codeartifact.ListSubPackageGroupsInput, func(*codeartifact.ListSubPackageGroupsOutput, bool) bool) error + ListSubPackageGroupsPagesWithContext(aws.Context, *codeartifact.ListSubPackageGroupsInput, func(*codeartifact.ListSubPackageGroupsOutput, bool) bool, ...request.Option) error + ListTagsForResource(*codeartifact.ListTagsForResourceInput) (*codeartifact.ListTagsForResourceOutput, error) ListTagsForResourceWithContext(aws.Context, *codeartifact.ListTagsForResourceInput, ...request.Option) (*codeartifact.ListTagsForResourceOutput, error) ListTagsForResourceRequest(*codeartifact.ListTagsForResourceInput) (*request.Request, *codeartifact.ListTagsForResourceOutput) @@ -222,6 +266,14 @@ type CodeArtifactAPI interface { UntagResourceWithContext(aws.Context, *codeartifact.UntagResourceInput, ...request.Option) (*codeartifact.UntagResourceOutput, error) UntagResourceRequest(*codeartifact.UntagResourceInput) (*request.Request, *codeartifact.UntagResourceOutput) + UpdatePackageGroup(*codeartifact.UpdatePackageGroupInput) (*codeartifact.UpdatePackageGroupOutput, error) + UpdatePackageGroupWithContext(aws.Context, *codeartifact.UpdatePackageGroupInput, ...request.Option) (*codeartifact.UpdatePackageGroupOutput, error) + UpdatePackageGroupRequest(*codeartifact.UpdatePackageGroupInput) (*request.Request, *codeartifact.UpdatePackageGroupOutput) + + UpdatePackageGroupOriginConfiguration(*codeartifact.UpdatePackageGroupOriginConfigurationInput) (*codeartifact.UpdatePackageGroupOriginConfigurationOutput, error) + UpdatePackageGroupOriginConfigurationWithContext(aws.Context, *codeartifact.UpdatePackageGroupOriginConfigurationInput, ...request.Option) (*codeartifact.UpdatePackageGroupOriginConfigurationOutput, error) + UpdatePackageGroupOriginConfigurationRequest(*codeartifact.UpdatePackageGroupOriginConfigurationInput) (*request.Request, *codeartifact.UpdatePackageGroupOriginConfigurationOutput) + UpdatePackageVersionsStatus(*codeartifact.UpdatePackageVersionsStatusInput) (*codeartifact.UpdatePackageVersionsStatusOutput, error) UpdatePackageVersionsStatusWithContext(aws.Context, *codeartifact.UpdatePackageVersionsStatusInput, ...request.Option) (*codeartifact.UpdatePackageVersionsStatusOutput, error) UpdatePackageVersionsStatusRequest(*codeartifact.UpdatePackageVersionsStatusInput) (*request.Request, *codeartifact.UpdatePackageVersionsStatusOutput) diff --git a/service/codeartifact/doc.go b/service/codeartifact/doc.go index 49556b40039..e9afed3a0b4 100644 --- a/service/codeartifact/doc.go +++ b/service/codeartifact/doc.go @@ -11,10 +11,7 @@ // and another repository, which effectively merges their contents from the // point of view of a package manager client. // -// # CodeArtifact Components -// -// Use the information in this guide to help you work with the following CodeArtifact -// components: +// CodeArtifact concepts // // - Repository: A CodeArtifact repository contains a set of package versions // (https://docs.aws.amazon.com/codeartifact/latest/ug/welcome.html#welcome-concepts-package-version), @@ -22,7 +19,7 @@ // so a single repository can contain packages of any supported type. Each // repository exposes endpoints for fetching and publishing packages using // tools like the npm CLI, the Maven CLI ( mvn ), Python CLIs ( pip and twine), -// and NuGet CLIs (nuget and dotnet). +// NuGet CLIs (nuget and dotnet), and the Swift package manager ( swift ). // // - Domain: Repositories are aggregated into a higher-level entity known // as a domain. All package assets and metadata are stored in the domain, @@ -43,12 +40,23 @@ // npm (https://docs.aws.amazon.com/codeartifact/latest/ug/using-npm.html), // PyPI (https://docs.aws.amazon.com/codeartifact/latest/ug/using-python.html), // Maven (https://docs.aws.amazon.com/codeartifact/latest/ug/using-maven), -// and NuGet (https://docs.aws.amazon.com/codeartifact/latest/ug/using-nuget) +// NuGet (https://docs.aws.amazon.com/codeartifact/latest/ug/using-nuget), +// Swift (https://docs.aws.amazon.com/codeartifact/latest/ug/using-swift), +// and generic (https://docs.aws.amazon.com/codeartifact/latest/ug/using-generic) // package formats. In CodeArtifact, a package consists of: A name (for example, // webpack is the name of a popular npm package) An optional namespace (for // example, @types in @types/node) A set of versions (for example, 1.0.0, // 1.0.1, 1.0.2, etc.) Package-level metadata (for example, npm tags) // +// - Package group: A group of packages that match a specified definition. +// Package groups can be used to apply configuration to multiple packages +// that match a defined pattern using package format, package namespace, +// and package name. You can use package groups to more conveniently configure +// package origin controls for multiple packages. Package origin controls +// are used to block or allow ingestion or publishing of new package versions, +// which protects users from malicious actions known as dependency substitution +// attacks. +// // - Package version: A version of a package, such as @types/node 12.6.9. // The version number format and semantics vary for different package formats. // For example, npm package versions must conform to the Semantic Versioning @@ -65,7 +73,7 @@ // - Asset: An individual file stored in CodeArtifact associated with a package // version, such as an npm .tgz file or Maven POM and JAR files. // -// CodeArtifact supports these operations: +// CodeArtifact supported API operations // // - AssociateExternalConnection: Adds an existing external connection to // a repository. @@ -73,7 +81,9 @@ // - CopyPackageVersions: Copies package versions from one repository to // another repository in the same domain. // -// - CreateDomain: Creates a domain +// - CreateDomain: Creates a domain. +// +// - CreatePackageGroup: Creates a package group. // // - CreateRepository: Creates a CodeArtifact repository in a domain. // @@ -85,6 +95,9 @@ // // - DeletePackage: Deletes a package and all associated package versions. // +// - DeletePackageGroup: Deletes a package group. Does not delete packages +// or package versions that are associated with a package group. +// // - DeletePackageVersions: Deletes versions of a package. After a package // has been deleted, it can be republished, but its assets and metadata cannot // be restored because they have been permanently removed from storage. @@ -100,6 +113,9 @@ // - DescribePackage: Returns a PackageDescription (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageDescription.html) // object that contains details about a package. // +// - DescribePackageGroup: Returns a PackageGroup (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageGroup.html) +// object that contains details about a package group. +// // - DescribePackageVersion: Returns a PackageVersionDescription (https://docs.aws.amazon.com/codeartifact/latest/APIReference/API_PackageVersionDescription.html) // object that contains details about a package version. // @@ -113,6 +129,9 @@ // - DisassociateExternalConnection: Removes an existing external connection // from a repository. // +// - GetAssociatedPackageGroup: Returns the most closely associated package +// group to the specified package. +// // - GetAuthorizationToken: Generates a temporary authorization token for // accessing repositories in the domain. The token expires the authorization // period has passed. The default authorization period is 12 hours and can @@ -129,16 +148,25 @@ // // - GetRepositoryEndpoint: Returns the endpoint of a repository for a specific // package format. A repository has one endpoint for each package format: -// maven npm nuget pypi +// generic maven npm nuget pypi swift // // - GetRepositoryPermissionsPolicy: Returns the resource policy that is // set on a repository. // +// - ListAllowedRepositoriesForGroup: Lists the allowed repositories for +// a package group that has origin configuration set to ALLOW_SPECIFIC_REPOSITORIES. +// +// - ListAssociatedPackages: Returns a list of packages associated with the +// requested package group. +// // - ListDomains: Returns a list of DomainSummary objects. Each returned // DomainSummary object contains information about a domain. // // - ListPackages: Lists the packages in a repository. // +// - ListPackageGroups: Returns a list of package groups in the requested +// domain. +// // - ListPackageVersionAssets: Lists the assets for a given package version. // // - ListPackageVersionDependencies: Returns a list of the direct dependencies @@ -152,6 +180,9 @@ // // - ListRepositoriesInDomain: Returns a list of the repositories in a domain. // +// - ListSubPackageGroups: Returns a list of direct children of the specified +// package group. +// // - PublishPackageVersion: Creates a new package version containing one // or more assets. // @@ -164,6 +195,12 @@ // - PutRepositoryPermissionsPolicy: Sets the resource policy on a repository // that specifies permissions to access it. // +// - UpdatePackageGroup: Updates a package group. This API cannot be used +// to update a package group's origin configuration or pattern. +// +// - UpdatePackageGroupOriginConfiguration: Updates the package origin configuration +// for a package group. +// // - UpdatePackageVersionsStatus: Updates the status of one or more versions // of a package. //