def checkout_license()

in managed-entitlements/src/managed_entitlements_sample.py [0:0]


def checkout_license(KeyFingerprint, ProductSKU, ProductKeyEntitlementName, ProductKeyUnit, ProductKeyValue):
    lm_client = get_client(default_region)
    response = lm_client.checkout_license(
        CheckoutType = "PROVISIONAL",
        Entitlements = [{
            "Name": ProductKeyEntitlementName,
            "Unit": ProductKeyUnit,
            "Value": ProductKeyValue
        }],
        KeyFingerprint = KeyFingerprint,
        ProductSKU = ProductSKU,
        Beneficiary = "My Beneficiary",
        ClientToken = str(uuid.uuid4())
    )
    print('AWS License Manager - Checkout License API response:')
    pprint.pprint(response)
    return response