منصة جزائرية للخدمات والمنتجات الرقمية مع حماية الضمان (Escrow)
Trusted Algerian marketplace for digital services and products with escrow protection.
Important
🚧 مشروع مفتوح المصدر قيد التطوير النشط (Work In Progress)
هذا المشروع في مرحلة بناء وتطوير مستمر، وهو مفتوح المصدر بالكامل ومتاح لكافة المطورين للمساهمة والتطوير. نرحب بكل الأفكار، تحسينات الكود، إصلاحات الأخطاء، وطلبات السحب (Pull Requests). يرجى مراجعة دليل المساهمة (CONTRIBUTING.md) و سياسة الأمان (SECURITY.md).
This repository is under active development and open for public community contributions. We warmly welcome pull requests, security audits, feature ideas, and feedback!
|
Protected Payments Checkout, hold, release, and refund logic |
Realtime Operations Rooms, chat, notifications, and activity flow |
Trust Layer KYC-aware workflows, moderation, and support |
Deployment Ready Health checks, Docker stack, staging, and tests |
DZHub (دزاير هب) is an escrow-first platform designed specifically for digital services and digital products. A transaction remains structured, traceable, and protected from the moment a buyer commits payment until the deal is successfully completed or safely refunded.
Instead of treating escrow as an add-on, the platform places it at the center of the product experience. Listings, rooms, support, notifications, moderation, invoices, and payment state changes are all connected to the transaction lifecycle.
- A seller creates a listing or starts a deal.
- A buyer initiates payment through the platform.
- The amount is held in escrow rather than released immediately.
- Both sides continue inside the protected deal room.
- The transaction concludes through release, refund, or staff review.
- Escrow payment lifecycle with hold, release, and refund states
- Fixed-price listings and auction listings
- Invoice visibility and payment audit continuity
- Dedicated success and checkout flows for buyer confidence
- Real-time escrow rooms
- Private chat and message attachments
- Notification polling and room activity updates
- Structured communication tied directly to the transaction
- KYC-aware verification states
- Support ticket system and staff review workflows
- Moderation paths for withdrawals, rooms, and user actions
- Protected staff surfaces with access controls
- Docker and production-style compose stack
- Health endpoint for uptime and orchestration checks
- Deployment checklist and env templates
- Full test suite covering core business flows
Authentication Flow |
Trust and Product Layer |
Marketplace Experience |
- Python 3
- Django 4.2+
- Django Channels
- Celery
- PostgreSQL
- Redis
- Docker and Docker Compose
- Stripe
- Google OAuth via
django-allauth - SMTP email delivery
flowchart LR
U[Users] --> W[Web App]
W --> D[(PostgreSQL)]
W --> R[(Redis)]
W --> S[Stripe]
W --> M[SMTP]
W --> C[Celery Worker]
W --> B[Celery Beat]
C --> D
C --> R
B --> R
S --> WH[Webhook Endpoint]
WH --> W
core/ Django settings and project configuration
main/ Main application: views, models, tests, services
templates/ HTML templates
static/ CSS, JavaScript, and image assets
docker/ Entrypoint and healthcheck helpers
.env.example Local development template
.env.production.example Production environment template
DEPLOYMENT_CHECKLIST.md Launch and deployment checklist
- Python 3.9+
- PostgreSQL
- Redis
- Virtual environment support
- Clone the repository
git clone https://github.com/test-bit-sys/escrow-.git
cd escrow-- Create and activate a virtual environment
# Windows
python -m venv venv
venv\Scripts\activate
# macOS / Linux
python -m venv venv
source venv/bin/activate- Install dependencies
pip install -r requirements.txt- Create the environment file
cp .env.example .env- Run database setup
python manage.py migrate
python manage.py createsuperuser- Start the app
python manage.py runserverLocal HTTPS for preview:
.\run_dev.ps1 -HttpsThen open https://localhost:8000/. The generated certificate is for local development only, so the browser may ask you to accept it the first time.
If port 8000 is still used by an old HTTP server, replace it with:
.\run_dev.ps1 -Https -ReplacePortContainerized local stack:
docker compose up --buildProduction-style stack:
cp .env.production.example .env.production
docker compose -f docker-compose.prod.yml up --build -dImportant environment variables:
DJANGO_SECRET_KEYDJANGO_DEBUGSITE_URLDJANGO_ALLOWED_HOSTSDJANGO_CSRF_TRUSTED_ORIGINSDATABASE_URLorDB_*REDIS_URLorREDIS_HOST/REDIS_PORTSTRIPE_PUBLIC_KEYSTRIPE_SECRET_KEYSTRIPE_WEBHOOK_SECRETEMAIL_HOST_USEREMAIL_HOST_PASSWORD
Reference files:
Built-in health endpoints:
/health//health/?format=text
These are suitable for local verification, staging uptime checks, and container health probes.
The current payment lifecycle is:
- A checkout is created for a deal.
- A successful payment moves the deal into escrow.
- The escrow room becomes active.
- The platform resolves the deal through release or refund logic.
- Invoice and audit details remain available in the system.
For local Stripe webhook testing:
stripe listen --forward-to http://127.0.0.1:8000/stripe/webhook/Core verification:
python manage.py check
python manage.py test --keepdbDeployment-oriented verification:
python manage.py check --deployFor staging or production, ensure:
DJANGO_DEBUG=False- PostgreSQL is available
- Redis is available
- Celery worker and beat are running
- Stripe webhook configuration matches
SITE_URL - Email delivery is configured
- Secret values are real and not placeholders
هذا المشروع يرحب بكل المطورين والمهتمين بالبرمجيات الحرة! إذا كنت ترغب في المساهمة بكود، تحسين الواجهة، أو الإبلاغ عن أخطاء، فالباب مفتوح لك بالكامل.
- 🌐 تعدد اللغات (i18n): استكمال تعريب وتدويل النصوص (عربي / إنجليزي / فرنسي).
- 💳 بوابات الدفع (Payment Adapters): إضافة بوابات دفع محلية (مثل BaridiMob / Satim / CIB) أو تجريبية.
- 📱 تحسينات تجربة المستخدم (UI/UX Polish): تحسين استجابة الصفحات على الهواتف والأجهزة اللوحية ورفع مستوى إمكانية الوصول (Accessibility).
- 🧪 زيادة التغطية الاختبارية (Tests): كتابة المزيد من اختبارات الوحدة (Unit Tests) لتدفقات النزاع والمحادثات الحية.
- ⚡ تحسين أداء WebSockets: تحسين قنوات الاتصال الحي (Django Channels) وحفظ الرسائل في Redis.
- 🔒 تدقيق ومراجعة الأمان: المساعدة في فحص تدفقات الصرف والحجز وضمان سلامة المنطق المالي.
يرجى مراجعة دليل المساهمة CONTRIBUTING.md للبدء في خطوتك الأولى، ولا تتردد في فتح Issue جديدة لمناقشة أي فكرة قبل البدء بها!
This project is distributed under the MIT License.
See LICENSE for full details.


