AWS License Manager

2020/11/23 - AWS License Manager - 3 updated api methods

Changes  AWS License Manager now provides the ability for license administrators to be able to associate license configurations to AMIs shared with their AWS account

ListAssociationsForLicenseConfiguration (updated) Link ¶
Changes (response)
{'LicenseConfigurationAssociations': {'AmiAssociationScope': 'string'}}

Lists the resource associations for the specified license configuration.

Resource associations need not consume licenses from a license configuration. For example, an AMI or a stopped instance might not consume a license (depending on the license rules).

See also: AWS API Documentation

Request Syntax

client.list_associations_for_license_configuration(
    LicenseConfigurationArn='string',
    MaxResults=123,
    NextToken='string'
)
type LicenseConfigurationArn

string

param LicenseConfigurationArn

[REQUIRED]

Amazon Resource Name (ARN) of a license configuration.

type MaxResults

integer

param MaxResults

Maximum number of results to return in a single call.

type NextToken

string

param NextToken

Token for the next set of results.

rtype

dict

returns

Response Syntax

{
    'LicenseConfigurationAssociations': [
        {
            'ResourceArn': 'string',
            'ResourceType': 'EC2_INSTANCE'|'EC2_HOST'|'EC2_AMI'|'RDS'|'SYSTEMS_MANAGER_MANAGED_INSTANCE',
            'ResourceOwnerId': 'string',
            'AssociationTime': datetime(2015, 1, 1),
            'AmiAssociationScope': 'string'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • LicenseConfigurationAssociations (list) --

      Information about the associations for the license configuration.

      • (dict) --

        Describes an association with a license configuration.

        • ResourceArn (string) --

          Amazon Resource Name (ARN) of the resource.

        • ResourceType (string) --

          Type of server resource.

        • ResourceOwnerId (string) --

          ID of the AWS account that owns the resource consuming licenses.

        • AssociationTime (datetime) --

          Time when the license configuration was associated with the resource.

        • AmiAssociationScope (string) --

          Scope of AMI associations.

    • NextToken (string) --

      Token for the next set of results.

ListLicenseSpecificationsForResource (updated) Link ¶
Changes (response)
{'LicenseSpecifications': {'AmiAssociationScope': 'string'}}

Describes the license configurations for the specified resource.

See also: AWS API Documentation

Request Syntax

client.list_license_specifications_for_resource(
    ResourceArn='string',
    MaxResults=123,
    NextToken='string'
)
type ResourceArn

string

param ResourceArn

[REQUIRED]

Amazon Resource Name (ARN) of a resource that has an associated license configuration.

type MaxResults

integer

param MaxResults

Maximum number of results to return in a single call.

type NextToken

string

param NextToken

Token for the next set of results.

rtype

dict

returns

Response Syntax

{
    'LicenseSpecifications': [
        {
            'LicenseConfigurationArn': 'string',
            'AmiAssociationScope': 'string'
        },
    ],
    'NextToken': 'string'
}

Response Structure

  • (dict) --

    • LicenseSpecifications (list) --

      License configurations associated with a resource.

      • (dict) --

        Details for associating a license configuration with a resource.

        • LicenseConfigurationArn (string) --

          Amazon Resource Name (ARN) of the license configuration.

        • AmiAssociationScope (string) --

          Scope of AMI associations.

    • NextToken (string) --

      Token for the next set of results.

UpdateLicenseSpecificationsForResource (updated) Link ¶
Changes (request)
{'AddLicenseSpecifications': {'AmiAssociationScope': 'string'},
 'RemoveLicenseSpecifications': {'AmiAssociationScope': 'string'}}

Adds or removes the specified license configurations for the specified AWS resource.

You can update the license specifications of AMIs, instances, and hosts. You cannot update the license specifications for launch templates and AWS CloudFormation templates, as they send license configurations to the operation that creates the resource.

See also: AWS API Documentation

Request Syntax

client.update_license_specifications_for_resource(
    ResourceArn='string',
    AddLicenseSpecifications=[
        {
            'LicenseConfigurationArn': 'string',
            'AmiAssociationScope': 'string'
        },
    ],
    RemoveLicenseSpecifications=[
        {
            'LicenseConfigurationArn': 'string',
            'AmiAssociationScope': 'string'
        },
    ]
)
type ResourceArn

string

param ResourceArn

[REQUIRED]

Amazon Resource Name (ARN) of the AWS resource.

type AddLicenseSpecifications

list

param AddLicenseSpecifications

ARNs of the license configurations to add.

  • (dict) --

    Details for associating a license configuration with a resource.

    • LicenseConfigurationArn (string) -- [REQUIRED]

      Amazon Resource Name (ARN) of the license configuration.

    • AmiAssociationScope (string) --

      Scope of AMI associations.

type RemoveLicenseSpecifications

list

param RemoveLicenseSpecifications

ARNs of the license configurations to remove.

  • (dict) --

    Details for associating a license configuration with a resource.

    • LicenseConfigurationArn (string) -- [REQUIRED]

      Amazon Resource Name (ARN) of the license configuration.

    • AmiAssociationScope (string) --

      Scope of AMI associations.

rtype

dict

returns

Response Syntax

{}

Response Structure

  • (dict) --