View a markdown version of this page

CreatePremiumRepository - Amazon Elastic Container Registry Public

CreatePremiumRepository

Creates a premium repository in a public registry for paid content that's sold through AWS Marketplace. Your registry must be verified and have an approved custom registry alias; otherwise, the request fails with ValidationException. The repository starts in the DRAFT state, and you make it available with SetRepositoryState.

Request Syntax

{ "catalogData": { "aboutText": "string", "architectures": [ "string" ], "categories": [ "string" ], "description": "string", "logoImageBlob": blob, "operatingSystems": [ "string" ], "usageText": "string" }, "marketplaceProducts": [ "string" ], "repositoryName": "string", "tags": [ { "Key": "string", "Value": "string" } ] }

Request Parameters

For information about the parameters that are common to all actions, see Common Parameters.

The request accepts the following data in JSON format.

catalogData

The details about the premium repository that are publicly visible in the Amazon ECR Public Gallery. A premium repository is listed in the Amazon ECR Public Gallery when it's AVAILABLE and at least one of its AWS Marketplace products is public.

Type: RepositoryCatalogDataInput object

Required: No

marketplaceProducts

The list of AWS Marketplace product IDs for the premium repository. You can specify from one to five product IDs. Your account must own each product, and each product must have an Amazon ECR Public Premium delivery option. You can't specify the same product ID more than once.

Type: Array of strings

Array Members: Minimum number of 1 item. Maximum number of 5 items.

Length Constraints: Minimum length of 1. Maximum length of 255.

Pattern: [A-Za-z0-9_-]+

Required: Yes

repositoryName

The name to use for the premium repository. You can specify the name on its own (for example nginx-web-app) or prepend a namespace to group the repository into a category (for example project-a/nginx-web-app). You can give a premium repository the same name as a free repository in the same registry.

Type: String

Length Constraints: Minimum length of 2. Maximum length of 205.

Pattern: [a-z0-9]+((\.|_|__|-+)[a-z0-9]+)*(\/[a-z0-9]+((\.|_|__|-+)[a-z0-9]+)*)*

Required: Yes

tags

The metadata that you apply to the premium repository to help categorize and organize your repositories. Each tag consists of a key and an optional value. You define both of them. Tag keys can have a maximum character length of 128 characters, and tag values can have a maximum length of 256 characters.

Type: Array of Tag objects

Array Members: Minimum number of 0 items. Maximum number of 200 items.

Required: No

Response Syntax

{ "catalogData": { "aboutText": "string", "architectures": [ "string" ], "artifactTypes": [ "string" ], "badges": [ "string" ], "categories": [ "string" ], "description": "string", "logoUrl": "string", "marketplaceCertified": boolean, "operatingSystems": [ "string" ], "usageText": "string" }, "premiumRepository": { "associatedRepositories": [ { "repositoryName": "string", "repositoryType": "string" } ], "createdAt": number, "marketplaceProducts": [ "string" ], "registryId": "string", "repositoryArn": "string", "repositoryName": "string", "repositoryUri": "string", "state": "string" } }

Response Elements

If the action is successful, the service sends back an HTTP 200 response.

The following data is returned in JSON format by the service.

catalogData

The catalog data for the premium repository that was created.

Type: RepositoryCatalogData object

premiumRepository

The premium repository that was created.

Type: PremiumRepository object

Errors

For information about the errors that are common to all actions, see Common Error Types.

InvalidParameterException

The specified parameter is invalid. Review the available parameters for the API request.

message

The error message associated with the exception.

HTTP Status Code: 400

InvalidTagParameterException

An invalid parameter has been specified. Tag keys can have a maximum character length of 128 characters, and tag values can have a maximum length of 256 characters.

message

The error message associated with the exception.

HTTP Status Code: 400

LimitExceededException

The operation didn't succeed because it would have exceeded a service limit for your account. For more information, see Amazon ECR Public service quotas in the Amazon Elastic Container Registry Public User Guide.

message

The error message associated with the exception.

HTTP Status Code: 400

RepositoryAlreadyExistsException

The specified repository already exists in the specified registry. Choose a different repository name, or use the existing repository.

message

The error message associated with the exception.

HTTP Status Code: 400

ServerException

These errors are usually caused by a server-side issue. Retry the request. If it continues to fail, contact AWS Support.

message

The error message associated with the exception.

HTTP Status Code: 500

TooManyTagsException

The list of tags on the repository is over the limit. A repository can have up to 50 tags. Remove tags with UntagResource, or specify fewer tags, then try again.

message

The error message associated with the exception.

HTTP Status Code: 400

UnsupportedCommandException

The action isn't supported in this Region. Check that the action is available in the AWS Region that you're using, and try again in a supported Region.

message

The error message associated with the exception.

HTTP Status Code: 400

ValidationException

There was an error validating the request. Check the request parameters and try again.

message

The error message associated with the exception.

HTTP Status Code: 400

See Also

For more information about using this API in one of the language-specific AWS SDKs, see the following: