# -*- coding: utf-8 -*-

"""Generate the Resilient customizations required for fn_outbound_email"""

from __future__ import print_function
from resilient_circuits.util import ImportDefinition

def codegen_reload_data():
    """Parameters to codegen used to generate the fn_outbound_email package"""
    reload_params = {"package": u"fn_outbound_email",
                    "incident_fields": [], 
                    "action_fields": [u"mail_cc", u"mail_to"], 
                    "function_params": [u"mail_bcc", u"mail_body_html", u"mail_body_text", u"mail_cc", u"mail_from", u"mail_incident_id", u"mail_subject", u"mail_to"], 
                    "datatables": [], 
                    "message_destinations": [u"email_outbound"], 
                    "functions": [u"send_email"], 
                    "phases": [], 
                    "automatic_tasks": [], 
                    "scripts": [], 
                    "workflows": [u"example_send_incident_email_html", u"example_send_incident_email_text"], 
                    "actions": [u"Example: Send Incident Email HTML", u"Example: Send Incident Email Text"], 
                    "incident_artifact_types": [] 
                    }
    return reload_params


def customization_data(client=None):
    """Produce any customization definitions (types, fields, message destinations, etc)
       that should be installed by `resilient-circuits customize`
    """

    # This import data contains:
    #   Action fields:
    #     mail_cc
    #     mail_to
    #   Function inputs:
    #     mail_bcc
    #     mail_body_html
    #     mail_body_text
    #     mail_cc
    #     mail_from
    #     mail_incident_id
    #     mail_subject
    #     mail_to
    #   Message Destinations:
    #     email_outbound
    #   Functions:
    #     send_email
    #   Workflows:
    #     example_send_incident_email_html
    #     example_send_incident_email_text
    #   Rules:
    #     Example: Send Incident Email HTML
    #     Example: Send Incident Email Text


    yield ImportDefinition(u"""
<KEY>
"""
    )
