<?xml version="1.0" encoding="UTF-8"?>
<rss version="2.0" xmlns:atom="http://www.w3.org/2005/Atom" xmlns:dc="http://purl.org/dc/elements/1.1/">
  <channel>
    <title>DEV Community: Stephen Wereko</title>
    <description>The latest articles on DEV Community by Stephen Wereko (@stephen_wereko_e6560b05c1).</description>
    <link>https://dev.to/stephen_wereko_e6560b05c1</link>
    <image>
      <url>https://media2.dev.to/dynamic/image/width=90,height=90,fit=cover,gravity=auto,format=auto/https:%2F%2Fdev-to-uploads.s3.us-east-2.amazonaws.com%2Fuploads%2Fuser%2Fprofile_image%2F3691793%2F167b46ed-ad27-4d4f-a6e5-64452b6d3855.jpg</url>
      <title>DEV Community: Stephen Wereko</title>
      <link>https://dev.to/stephen_wereko_e6560b05c1</link>
    </image>
    <atom:link rel="self" type="application/rss+xml" href="https://dev.to/feed/stephen_wereko_e6560b05c1"/>
    <language>en</language>
    <item>
      <title>How I Built an Enterprise Courier Suite with .NET 10 Web API, PostgreSQL, and Tailwind CSS</title>
      <dc:creator>Stephen Wereko</dc:creator>
      <pubDate>Mon, 20 Jul 2026 09:27:56 +0000</pubDate>
      <link>https://dev.to/stephen_wereko_e6560b05c1/how-i-built-an-enterprise-courier-suite-with-net-10-web-api-postgresql-and-tailwind-css-1m0j</link>
      <guid>https://dev.to/stephen_wereko_e6560b05c1/how-i-built-an-enterprise-courier-suite-with-net-10-web-api-postgresql-and-tailwind-css-1m0j</guid>
      <description>&lt;p&gt;Building a complete logistics engine isn't just about rendering CRUD forms. Real-world delivery applications require complex state machines, real-time dispatching logic, dynamic fare calculations, and multi-actor security roles.&lt;/p&gt;

&lt;p&gt;I recently finished architecting and releasing a production-ready **courier &amp;amp; logistics management system. Here is a technical breakdown of how I structured the architecture, solved the dispatching problem, and decoupled the backend for scale.&lt;/p&gt;




&lt;h2&gt;
  
  
  🏛️ System Architecture Overview
&lt;/h2&gt;

&lt;p&gt;To ensure high performance and future extensibility (such as plugging in native iOS or Android apps down the road), I separated the core backend completely from the web presentation layer.&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Backend:&lt;/strong&gt; ASP.NET Core (.NET 10) Web API&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Frontend:&lt;/strong&gt; ASP.NET Core MVC consuming the API&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Styling:&lt;/strong&gt; Tailwind CSS + SweetAlert UI event feedback&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Database:&lt;/strong&gt; PostgreSQL (Relational schema with custom indexing)
## ⚙️ Key Technical Challenges &amp;amp; Solutions&lt;/li&gt;
&lt;/ul&gt;

&lt;h3&gt;
  
  
  1. Dynamic Distance-Based Pricing
&lt;/h3&gt;

&lt;p&gt;Flat fees don't work for logistics startups. Long-distance trips undercharge the driver, while short trips turn away customers. &lt;/p&gt;

&lt;p&gt;I implemented a dynamic pricing algorithm inside the API engine that computes the delivery total using standard route parameters:&lt;/p&gt;

&lt;p&gt;$$\text{Total Fare} = \text{Base Fee} + (\text{Distance in km} \times \text{Per-km Rate})$$&lt;/p&gt;

&lt;p&gt;This allows administrators to adjust regional base fees and per-kilometer rates globally without modifying codebase rules.&lt;/p&gt;

&lt;h3&gt;
  
  
  2. Automatic Rider Dispatch Engine
&lt;/h3&gt;

&lt;p&gt;Manual dispatching creates massive operational bottlenecks. The system includes an automated assignment dispatcher that runs upon order creation:&lt;/p&gt;

&lt;ol&gt;
&lt;li&gt;Queries the PostgreSQL database for active riders marked as &lt;code&gt;Available&lt;/code&gt;.&lt;/li&gt;
&lt;li&gt;Evaluates current workload queues.&lt;/li&gt;
&lt;li&gt;Automatically attaches the order to the selected rider's active manifest.&lt;/li&gt;
&lt;li&gt;Triggers instant updates in the dedicated &lt;strong&gt;Rider Portal&lt;/strong&gt;.&lt;/li&gt;
&lt;/ol&gt;

&lt;h3&gt;
  
  
  3. Multi-Portal Isolation &amp;amp; Security
&lt;/h3&gt;

&lt;p&gt;The system features &lt;strong&gt;4 dedicated portals&lt;/strong&gt;:&lt;/p&gt;

&lt;ul&gt;
&lt;li&gt;
&lt;strong&gt;Admin Portal:&lt;/strong&gt; Fleet management, rate configurations, global reporting, and user roles.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Client Portal:&lt;/strong&gt; Order creation, real-time shipment tracking, and delivery history.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Rider Portal:&lt;/strong&gt; Mobile-first dashboard for active pickups, status updates, and daily run metrics.&lt;/li&gt;
&lt;li&gt;
&lt;strong&gt;Order Management Portal:&lt;/strong&gt; State machine handling transitions (&lt;code&gt;Pending&lt;/code&gt; ➔ &lt;code&gt;Dispatched&lt;/code&gt; ➔ &lt;code&gt;In Transit&lt;/code&gt; ➔ &lt;code&gt;Delivered&lt;/code&gt; / &lt;code&gt;Cancelled&lt;/code&gt;).&lt;/li&gt;
&lt;/ul&gt;

&lt;p&gt;Security includes token-based authentication and a complete email recovery flow for lost passwords.&lt;/p&gt;




&lt;h2&gt;
  
  
  🚀 Get the Full Source Code
&lt;/h2&gt;

&lt;p&gt;If you are a developer, freelancer, or startup founder looking to launch a delivery platform without spending 200+ hours coding backend state logic from scratch, the full commercial source code is now live on Codester!&lt;/p&gt;

&lt;p&gt;It includes full C# source files, Razor views, Tailwind styling pipelines, and a clean ``PostgreSQL database migration script.&lt;/p&gt;

&lt;p&gt;👉 &lt;strong&gt;&lt;a href="https://www.codester.com/items/67895/delivery-management-system-asp-net-core-mvc?ref=wrescoder" rel="noopener noreferrer"&gt;Get the Full Delivery Management System Source Code on Codester&lt;/a&gt;&lt;/strong&gt;&lt;/p&gt;

</description>
      <category>architecture</category>
      <category>backend</category>
      <category>dotnet</category>
      <category>showdev</category>
    </item>
    <item>
      <title>📁 Stop Messy Downloads Forever: Python Organizes Your Files Automatically ✅</title>
      <dc:creator>Stephen Wereko</dc:creator>
      <pubDate>Fri, 16 Jan 2026 19:05:07 +0000</pubDate>
      <link>https://dev.to/stephen_wereko_e6560b05c1/stop-messy-downloads-forever-python-organizes-your-files-automatically-16aj</link>
      <guid>https://dev.to/stephen_wereko_e6560b05c1/stop-messy-downloads-forever-python-organizes-your-files-automatically-16aj</guid>
      <description>&lt;p&gt;If your Downloads folder looks like a war zone 😭 (PDFs + images + zip files everywhere), you’re not alone.&lt;/p&gt;

&lt;p&gt;So I built a beginner-friendly Python script that automatically:&lt;/p&gt;

&lt;p&gt;✅ Organizes files into folders (PDFs / Images / Docs / Zips / Videos / Sheets)&lt;br&gt;
✅ Creates a folder for today’s date (YYYY-MM-DD)&lt;br&gt;
✅ Renames every file with a timestamp (date/time)&lt;br&gt;
✅ Prevents overwriting duplicates (_1, _2, _3…)&lt;/p&gt;

&lt;p&gt;Result: your Downloads folder becomes clean, sorted, and searchable ✅&lt;/p&gt;

&lt;p&gt;▶️ Video Tutorial (Silent Coding / No Talking)&lt;/p&gt;

&lt;p&gt;I recorded a quick walkthrough showing the before → code → run → after.&lt;/p&gt;

&lt;p&gt;📺 Watch it here: &lt;a href="https://youtu.be/A3Yz100IbLw" rel="noopener noreferrer"&gt;https://youtu.be/A3Yz100IbLw&lt;/a&gt;&lt;/p&gt;

&lt;p&gt;(You can also check my channel: &lt;a href="https://www.youtube.com/@CodeGees" rel="noopener noreferrer"&gt;https://www.youtube.com/@CodeGees&lt;/a&gt;&lt;br&gt;
)&lt;/p&gt;

&lt;p&gt;Downloads/&lt;br&gt;
  Images/2026-01-16/2026-01-16_14-20-05_photo.png&lt;br&gt;
  PDFs/2026-01-16/2026-01-16_14-20-05_report.pdf&lt;br&gt;
  Zips/2026-01-16/2026-01-16_14-20-05_project.zip&lt;br&gt;
import os&lt;br&gt;
from datetime import datetime&lt;/p&gt;

&lt;h1&gt;
  
  
  ✅ Downloads folder
&lt;/h1&gt;

&lt;p&gt;downloads_folder = os.path.join(os.path.expanduser("~"), "Downloads")&lt;/p&gt;

&lt;h1&gt;
  
  
  ✅ Today's date folder
&lt;/h1&gt;

&lt;p&gt;today_date = datetime.now().strftime("%Y-%m-%d")&lt;/p&gt;

&lt;h1&gt;
  
  
  ✅ File categories
&lt;/h1&gt;

&lt;p&gt;file_categories = {&lt;br&gt;
    "PDFs": (".pdf",),&lt;br&gt;
    "Images": (".png", ".jpg", ".jpeg", ".webp"),&lt;br&gt;
    "Docs": (".docx", ".txt"),&lt;br&gt;
    "Zips": (".zip", ".rar", ".7z"),&lt;br&gt;
    "Videos": (".mp4", ".mov"),&lt;br&gt;
    "Sheets": (".xlsx", ".csv"),&lt;br&gt;
}&lt;/p&gt;

&lt;h1&gt;
  
  
  ✅ Loop through downloads
&lt;/h1&gt;

&lt;p&gt;for filename in os.listdir(downloads_folder):&lt;br&gt;
    old_path = os.path.join(downloads_folder, filename)&lt;/p&gt;

&lt;div class="highlight js-code-highlight"&gt;
&lt;pre class="highlight plaintext"&gt;&lt;code&gt;# Skip folders
if os.path.isdir(old_path):
    continue

# Skip shortcuts/temp/system files
if filename.lower().endswith((".lnk", ".tmp", ".ini")):
    continue

# Find file extension
file_ext = os.path.splitext(filename)[1].lower()

# Pick category folder
category_name = next(
    (name for name, exts in file_categories.items() if file_ext in exts),
    "Other"
)

# Create target folder (type + date)
target_folder = os.path.join(downloads_folder, category_name, today_date)
os.makedirs(target_folder, exist_ok=True)

# Create timestamp rename
file_name, ext = os.path.splitext(filename)
timestamp = datetime.now().strftime("%Y-%m-%d_%H-%M-%S")
new_path = os.path.join(target_folder, f"{timestamp}_{file_name}{ext}")

# Avoid overwriting duplicates
counter = 1
while os.path.exists(new_path):
    new_path = os.path.join(target_folder, f"{timestamp}_{file_name}_{counter}{ext}")
    counter += 1

# Rename + move
os.rename(old_path, new_path)

print("✅", filename, "→", category_name)
&lt;/code&gt;&lt;/pre&gt;

&lt;/div&gt;

&lt;p&gt;print("\n🎉 Done! Downloads are now organized by type + date."&lt;/p&gt;

&lt;p&gt;✅ Try it Yourself&lt;/p&gt;

&lt;p&gt;Save the file as: downloads_folder_organizer.py&lt;/p&gt;

&lt;p&gt;Run it:&lt;br&gt;
python downloads_folder_organizer.py&lt;/p&gt;

</description>
    </item>
    <item>
      <title>I learned Python in 30 days to save my life. Here is my first script. Tags: #python #beginners #productivity #ghana</title>
      <dc:creator>Stephen Wereko</dc:creator>
      <pubDate>Sat, 03 Jan 2026 20:06:16 +0000</pubDate>
      <link>https://dev.to/stephen_wereko_e6560b05c1/i-learned-python-in-30-days-to-save-my-life-here-is-my-first-script-tags-python-beginners-32l3</link>
      <guid>https://dev.to/stephen_wereko_e6560b05c1/i-learned-python-in-30-days-to-save-my-life-here-is-my-first-script-tags-python-beginners-32l3</guid>
      <description>&lt;p&gt;In 2019, I lost my job and all my connections. By 2026, I was at my lowest point. I decided to fight back by learning Python in 30 days.&lt;/p&gt;

&lt;p&gt;I code on a laptop with broken keys and no microphone, so I record Silent Coding sessions. I am building tools for Accountants, Data Scientists, and Students.&lt;/p&gt;

&lt;p&gt;My latest script is a desktop cleaner that organizes hundreds of files in seconds.&lt;/p&gt;

&lt;p&gt;Watch the silent build here: [&lt;a href="https://www.youtube.com/watch?v=g9x5M90g5Wc&amp;amp;t=119s" rel="noopener noreferrer"&gt;https://www.youtube.com/watch?v=g9x5M90g5Wc&amp;amp;t=119s&lt;/a&gt;]&lt;/p&gt;

&lt;p&gt;I am proof that you can start again with nothing. Please subscribe to support a dev from Ghana.&lt;/p&gt;

</description>
    </item>
  </channel>
</rss>
