{% if user_info.get("name", "UNKNOWN") != "UNKNOWN" %}

Hello {{ user_info.get("name") }},

{% else %}

Hello,

{% endif %} {% if show_disclaimer %}
This email is being sent from a testing environment. Please ignore.
{% endif %}

Below you will find a summary of your recently uploaded documents.

{% if user_info.get("success", []) %}

Documents that have been successfully uploaded:

{% for data in user_info.get("success", []) %} {% endfor %}
Action Document Time Status Company Document Type Document Date
{{ data.get("source_type", "") }} {{ data.get("title", "") }} {{ data.get("created_at", "") }} {{ data.get("ingestion_status", "") }}
    {% for company in data.get("company_name", []) %} {% if company != "" %}
  • {{ company }}
  • {% endif %} {% endfor %}
{{ data.get("document_type", "") }} {{ data.get("document_date", "") }}
{% endif %} {% if user_info.get("failure", []) %}

Documents that have been rejected:

{% for data in user_info.get("failure", []) %} {% endfor %}
Action Document Time Status Rejection Cause
{{ data.get("source_type", "") }} {{ data.get("title", "") }} {{ data.get("created_at", "") }} (UTC) {{ data.get("ingestion_status", "") }} {{ data.get("rejection_reason", "") }}
{% endif %}