Skip to main content

licenses

Creates, updates, deletes or gets a license resource or lists licenses in a region

Overview

Namelicenses
TypeResource
DescriptionResource Type definition for AWS::LicenseManager::License
Idawscc.licensemanager.licenses

Fields

NameDatatypeDescription
product_skustringProductSKU of the license.
issuerobject
license_namestringName for the created license.
product_namestringProduct name for the created license.
home_regionstringHome region for the created license.
validityobject
entitlementsarray
beneficiarystringBeneficiary of the license.
consumption_configurationobject
license_metadataarray
license_arnstringAmazon Resource Name is a unique name for each resource.
statusstring
versionstringThe version of the license.
regionstringAWS region.

For more information, see AWS::LicenseManager::License.

Methods

NameResourceAccessible byRequired Params
create_resourcelicensesINSERTLicenseName, ProductName, Issuer, HomeRegion, Validity, ConsumptionConfiguration, Entitlements, region
delete_resourcelicensesDELETEIdentifier, region
update_resourcelicensesUPDATEIdentifier, PatchDocument, region
list_resourceslicenses_list_onlySELECTregion
get_resourcelicensesSELECTIdentifier, region

SELECT examples

Gets all properties from an individual license.

SELECT
region,
product_sku,
issuer,
license_name,
product_name,
home_region,
validity,
entitlements,
beneficiary,
consumption_configuration,
license_metadata,
license_arn,
status,
version
FROM awscc.licensemanager.licenses
WHERE
region = 'us-east-1' AND
Identifier = '{{ license_arn }}';

INSERT example

Use the following StackQL query and manifest file to create a new license resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.licensemanager.licenses (
Issuer,
LicenseName,
ProductName,
HomeRegion,
Validity,
Entitlements,
ConsumptionConfiguration,
region
)
SELECT
'{{ issuer }}',
'{{ license_name }}',
'{{ product_name }}',
'{{ home_region }}',
'{{ validity }}',
'{{ entitlements }}',
'{{ consumption_configuration }}',
'{{ region }}';

UPDATE example

Use the following StackQL query and manifest file to update a license resource, using stack-deploy.

/*+ update */
UPDATE awscc.licensemanager.licenses
SET PatchDocument = string('{{ {
"ProductSKU": product_sku,
"Issuer": issuer,
"LicenseName": license_name,
"ProductName": product_name,
"HomeRegion": home_region,
"Validity": validity,
"Entitlements": entitlements,
"Beneficiary": beneficiary,
"ConsumptionConfiguration": consumption_configuration,
"LicenseMetadata": license_metadata,
"Status": status
} | generate_patch_document }}')
WHERE
region = '{{ region }}' AND
Identifier = '{{ license_arn }}';

DELETE example

/*+ delete */
DELETE FROM awscc.licensemanager.licenses
WHERE
Identifier = '{{ license_arn }}' AND
region = 'us-east-1';

Permissions

To operate on the licenses resource, the following permissions are required:

license-manager:CreateLicense