def METHOD_NAME(cls, challenge):
    """
    This method is in used to access the data of a challenge in a format processable by the front end.
    :param challenge:
    :return: Challenge object, data dictionary to be returned to the user
    """
    challenge = DynamicChallenge.query.filter_by(id=challenge.id).first()
    data = {
        "id": challenge.id,
        "name": challenge.name,
        "value": challenge.value,
        "initial": challenge.initial,
        "decay": challenge.decay,
        "minimum": challenge.minimum,
        "description": challenge.description,
        "connection_info": challenge.connection_info,
        "category": challenge.category,
        "state": challenge.state,
        "max_attempts": challenge.max_attempts,
        "type": challenge.type,
        "type_data": {
            "id": cls.id,
            "name": cls.name,
            "templates": cls.templates,
            "scripts": cls.scripts,
        },
    }
    return data