Skip to main content

NCAA Digital Auction System - Software Design Document

Table of Contents

  1. System Overview
  2. Architecture
  3. Database Design (ERD)
  4. System Workflows
  5. Integration Points

System Overview

Purpose

The NCAA Digital Auction System is a comprehensive platform for managing tourism operator auctions in Tanzania's National Parks. The system handles the complete lifecycle from operator/investor registration to contract management with integrated payment processing.

Key Features

  • Dual Authentication System: Internal staff authentication + Safari Portal OAuth for operators/investors
  • Operator/Investor Registration: Document management and compliance tracking via NCAA portal
  • Auction Management: Complete auction lifecycle with automated status transitions
  • Real-time Bidding: WebSocket-based bidding system with live updates
  • Payment Processing: Safari Portal integration with GePG for control number generation
  • Contract Management: Automated contract generation and approval workflows
  • Notification System: Multi-channel notifications (Email, SMS, Push)

Technology Stack

  • Frontend: React.js SPA with modern UI components
  • Backend: Django 5.2.6 + Django REST Framework 3.16.1
  • Database: PostgreSQL with comprehensive indexing
  • Task Queue: Celery 5.5.0 + Redis for background processing
  • WebSockets: Django Channels with Redis channel layer
  • Authentication: JWT + Safari Portal OAuth integration
  • File Storage: Cloudinary for document and media storage
  • External Integration: Safari Portal API for authentication and GePG payment processing

User Types

  • Internal Staff: NCAA admin, auction admin, finance officer, compliance officer, system admin
  • External Users: Tourism operators and investors (authenticated via Safari Portal)

Architecture

High-Level System Architecture

Authentication Decision Flow


Database Design (ERD)

Entity Relationship Diagram


System Workflows

1. Complete Auction Lifecycle

Key Implementation Details:

Campsite Eligibility Criteria (Automatically Applied):

  • maintenance_status = 'operational'
  • is_available_for_allocation = true
  • approved_for_seasonal_camping = true
  • is_active = true

Auction Stages:

  1. Setup Phase: Season → Locations → Campsites → Auction Creation
  2. Application Phase: Applications → Fee Payment → Document Verification
  3. Inspection Phase: Time slot booking → Site inspections
  4. Bidding Phase: Real-time WebSocket bidding system
  5. Result Phase: Auto-generation → Notifications → Payments → Contracts

2. Safari Portal Authentication Flow

3. Bidding Process with Real-time Updates

4. Payment Processing with GePG Integration

5. Document Verification Workflow


Integration Points

Safari Portal Integration

Purpose:

  • Authentication: OAuth integration for operators/investors authentication
  • Payment Processing: GePG integration for control number generation and payment verification

Key Integration Points:

  1. OAuth Authentication

    • Safari Portal provides secure authentication for tourism operators
    • Returns user profile and company information
    • NCAA system creates/updates local user accounts with external data
  2. GePG Payment Gateway

    • Control number generation for application fees
    • Control number generation for campsite deposit payments
    • Payment status verification and tracking
    • Automated payment workflow integration
  3. Data Flow

    • Authentication: Safari Portal → NCAA System
    • Applications: Submitted directly in NCAA Portal (not via Safari Portal)
    • Payments: NCAA → Safari Portal → GePG → Payment Providers