# acc-tax-reighteen/email-claim-sender-attch-shell architecture

> Architecture diagram of the GitHub repository acc-tax-reighteen/email-claim-sender-attch-shell, generated by GitDiagram from its file tree, README and a sample of source files (last updated 2026-10-08). It is an AI-made overview: check details against the source.

- Interactive diagram: https://gitdiagram.com/acc-tax-reighteen/email-claim-sender-attch-shell
- Repository: https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell

## Overview

This is a small Python automation tool for sending one Shell claim email per invoice. The user supplies an Excel workbook and invoice PDFs, then runs the entry point: it stages the files, extracts the “Isian” sheet, and starts the sender. The sender reads configuration and invoice rows, matches each invoice to a PDF, builds an HTML email, and sends it through Gmail SMTP. Cleanup is performed by the entry point. Connections reflect the excerpts and README; unsampled behavior is not assumed.

Main entry points: [`Jalankan Sender.py`](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Jalankan%20Sender.py) (Pipeline runner), [`Dapur/2_GmailSender.py`](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/2_GmailSender.py) (Invoice sender), [`Dapur`](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/tree/main/Dapur) (Staged files), [`Dapur/1_EkstrakData.py`](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/1_EkstrakData.py) (Sheet extractor)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_orchestration["Orchestration"]
  node_excel_input["Claim workbook"]
  node_pdf_inputs["Invoice PDFs"]
  node_runner["Pipeline runner<br/>[Jalankan Sender.py]"]
end

subgraph group_preparation["Data preparation"]
  node_staged_files["Staged files"]
  node_extractor["Sheet extractor<br/>[1_EkstrakData.py]"]
  node_temp_workbook["Temporary workbook"]
end

subgraph group_delivery["Email delivery"]
  node_config["Email configuration<br/>[config.conf]"]
  node_sender["Invoice sender<br/>[2_GmailSender.py]"]
  node_email_builder["Email composer<br/>[2_GmailSender.py]"]
  node_gmail{{"Gmail SMTP"}}
end

node_user(("Operator"))

node_user -->|"runs"| node_runner
node_excel_input -->|"provides workbook"| node_runner
node_pdf_inputs -->|"provides attachments"| node_runner
node_runner -->|"copies inputs"| node_staged_files
node_runner -->|"cleans files"| node_staged_files
node_runner -->|"runs"| node_extractor
node_runner -->|"runs"| node_sender
node_staged_files -->|"provides workbook"| node_extractor
node_extractor -->|"writes"| node_temp_workbook
node_temp_workbook -->|"provides invoice rows"| node_sender
node_config -->|"provides settings"| node_sender
node_sender -->|"matches PDFs"| node_staged_files
node_sender -->|"provides invoice data"| node_email_builder
node_email_builder -->|"sends messages"| node_gmail

click node_excel_input "https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Surat%20Saffiela%20-%20130326.xlsm"
click node_runner "https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Jalankan%20Sender.py"
click node_staged_files "https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/tree/main/Dapur"
click node_extractor "https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/1_EkstrakData.py"
click node_temp_workbook "https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/tree/main/Dapur"
click node_config "https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/config.conf"
click node_sender "https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/2_GmailSender.py"
click node_email_builder "https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/2_GmailSender.py"

classDef toneNeutral fill:#f8fafc,stroke:#334155,stroke-width:1.5px,color:#0f172a
classDef toneBlue fill:#dbeafe,stroke:#2563eb,stroke-width:1.5px,color:#172554
classDef toneAmber fill:#fef3c7,stroke:#d97706,stroke-width:1.5px,color:#78350f
classDef toneMint fill:#dcfce7,stroke:#16a34a,stroke-width:1.5px,color:#14532d
classDef toneRose fill:#ffe4e6,stroke:#e11d48,stroke-width:1.5px,color:#881337
classDef toneIndigo fill:#e0e7ff,stroke:#4f46e5,stroke-width:1.5px,color:#312e81
classDef toneTeal fill:#ccfbf1,stroke:#0f766e,stroke-width:1.5px,color:#134e4a
class node_excel_input,node_pdf_inputs,node_runner toneBlue
class node_staged_files,node_extractor,node_temp_workbook toneAmber
class node_config,node_sender,node_email_builder,node_gmail toneMint
class node_user toneIndigo
```

## Components

### Orchestration

- [Claim workbook](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Surat%20Saffiela%20-%20130326.xlsm): `Surat Saffiela - 130326.xlsm`
- **Invoice PDFs**
- [Pipeline runner](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Jalankan%20Sender.py): `Jalankan Sender.py`

### Data preparation

- [Staged files](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/tree/main/Dapur): `Dapur`
- [Sheet extractor](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/1_EkstrakData.py): `Dapur/1_EkstrakData.py`
- [Temporary workbook](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/tree/main/Dapur): `Dapur`

### Email delivery

- [Email configuration](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/config.conf): `Dapur/config.conf`
- [Invoice sender](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/2_GmailSender.py): `Dapur/2_GmailSender.py`
- [Email composer](https://github.com/acc-tax-reighteen/email-claim-sender-attch-shell/blob/main/Dapur/2_GmailSender.py): `Dapur/2_GmailSender.py`
- **Gmail SMTP**

### Other components

- **Operator**

## Connections

- Operator → Pipeline runner: runs (evidence: `README.md`)
- Claim workbook → Pipeline runner: provides workbook (evidence: `README.md`)
- Invoice PDFs → Pipeline runner: provides attachments (evidence: `README.md`)
- Pipeline runner → Staged files: copies inputs (evidence: `Jalankan Sender.py`)
- Pipeline runner → Staged files: cleans files (evidence: `Jalankan Sender.py`)
- Pipeline runner → Sheet extractor: runs (evidence: `Jalankan Sender.py`)
- Pipeline runner → Invoice sender: runs (evidence: `Jalankan Sender.py`)
- Staged files → Sheet extractor: provides workbook (evidence: `Dapur/1_EkstrakData.py`)
- Sheet extractor → Temporary workbook: writes (evidence: `Dapur/1_EkstrakData.py`)
- Temporary workbook → Invoice sender: provides invoice rows (evidence: `Dapur/2_GmailSender.py`)
- Email configuration → Invoice sender: provides settings (evidence: `Dapur/2_GmailSender.py`)
- Invoice sender → Staged files: matches PDFs (evidence: `Dapur/2_GmailSender.py`)
- Invoice sender → Email composer: provides invoice data (evidence: `Dapur/2_GmailSender.py`)
- Email composer → Gmail SMTP: sends messages (evidence: `Dapur/2_GmailSender.py`)
