from datetime import datetime


def create_envelope(payload: dict) -> dict:
    """
    Creates a dictionary with event label, timestamp and message field
    :param payload: The payload dict
    :return: An event message dictionary
    """

    payload['timestamp'] = datetime.utcnow().timestamp()
    if 'event' not in payload:
        payload['event'] = 'cs.unknown'
    if 'message' not in payload:
        payload['message'] = None

    return payload