# shail-712/image-processing-cicd architecture

> Architecture diagram of the GitHub repository shail-712/image-processing-cicd, 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/shail-712/image-processing-cicd
- Repository: https://github.com/shail-712/image-processing-cicd

## Overview

This is a Flask image-processing service. Clients submit images to resize, compress, convert, or grayscale; the API validates inputs, delegates each transform to the processing module, and returns the resulting image. The API also exposes a health check. The graph covers runtime behavior only; CI/CD and deployment are documented but are not part of the service’s runtime architecture.

Main entry points: [`app.py`](https://github.com/shail-712/image-processing-cicd/blob/main/app.py) (Flask API), [`image_processor.py`](https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.py) (Resize)

## Diagram (Mermaid)

```mermaid
flowchart TD

subgraph group_api["HTTP API"]
  node_api["Flask API<br/>[app.py]"]
  node_health["Health Check<br/>[app.py]"]
end

subgraph group_processing["Image Processing"]
  node_resize["Resize<br/>[image_processor.py]"]
  node_compress["Compress<br/>[image_processor.py]"]
  node_convert["Format Convert<br/>[image_processor.py]"]
  node_grayscale["Grayscale<br/>[image_processor.py]"]
end

node_client(("HTTP Client"))

node_client -->|"submits image"| node_api
node_api -->|"calls resize"| node_resize
node_api -->|"calls compress"| node_compress
node_api -->|"calls convert"| node_convert
node_api -->|"calls grayscale"| node_grayscale
node_resize -->|"returns image"| node_api
node_compress -->|"returns image"| node_api
node_convert -->|"returns image"| node_api
node_grayscale -->|"returns image"| node_api
node_client -->|"checks status"| node_health
node_health -->|"returns status"| node_client
node_api -->|"returns response"| node_client

click node_api "https://github.com/shail-712/image-processing-cicd/blob/main/app.py"
click node_health "https://github.com/shail-712/image-processing-cicd/blob/main/app.py"
click node_resize "https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.py"
click node_compress "https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.py"
click node_convert "https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.py"
click node_grayscale "https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.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_api,node_health,node_client toneBlue
class node_resize,node_compress,node_convert,node_grayscale toneAmber
```

## Components

### HTTP API

- [Flask API](https://github.com/shail-712/image-processing-cicd/blob/main/app.py): `app.py`
- [Health Check](https://github.com/shail-712/image-processing-cicd/blob/main/app.py): `app.py`

### Image Processing

- [Resize](https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.py): `image_processor.py`
- [Compress](https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.py): `image_processor.py`
- [Format Convert](https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.py): `image_processor.py`
- [Grayscale](https://github.com/shail-712/image-processing-cicd/blob/main/image_processor.py): `image_processor.py`

### Other components

- **HTTP Client**

## Connections

- HTTP Client → Flask API: submits image (evidence: `README.md`)
- Flask API → Resize: calls resize (evidence: `app.py`)
- Flask API → Compress: calls compress (evidence: `app.py`)
- Flask API → Format Convert: calls convert (evidence: `app.py`)
- Flask API → Grayscale: calls grayscale (evidence: `app.py`)
- Resize → Flask API: returns image (evidence: `app.py`)
- Compress → Flask API: returns image (evidence: `app.py`)
- Format Convert → Flask API: returns image (evidence: `app.py`)
- Grayscale → Flask API: returns image (evidence: `app.py`)
- HTTP Client → Health Check: checks status (evidence: `README.md`)
- Health Check → HTTP Client: returns status (evidence: `app.py`)
- Flask API → HTTP Client: returns response (evidence: `app.py`)
