def get_playable_endpoints()

in lambda-functions/aemp-cloudfront-sync-function/function.py [0:0]


def get_playable_endpoints(assetIds):

    endpoints = []

    for assetId in assetIds:
        response = aemp_vod.describe_asset(Id=assetId)
        log.debug(f'Asset Detail {response["EgressEndpoints"]}')
        for endpoint in response["EgressEndpoints"]:
            endpoints.append(endpoint["Url"])

    log.debug(f'Endpoints {endpoints}')
    return endpoints