def lambda_handler()

in Bot2/ImageUpdate/hello_world/twitterUpdateImage.py [0:0]


def lambda_handler(event, context):
    try:
        #patch_all()
        authTwitter = authenticate_twitter()

        nbofImageFaces = process_messages(authTwitter, event)
        logger.info("Images with Faces: " + str(nbofImageFaces))
    except Exception as e: # take care of all those ugly errors if there are some
        print(e)

    return {
            "statusCode": 200,
            "body": json.dumps(
                {"message": "Update Image on twitter"}
            ),
        }