How ruyanga/ist-technical-assessment-be works
Merci is a Django REST backend for frontend-driven JWT authentication, user management, and purchase workflows. A staff member submits a purchase request with items; role-based approvers review it, and approval can produce a purchase order. Users can submit and inspect receipts, while document endpoints support proforma extraction and receipt validation. The graph separates account access, request and approval handling, purchasing, and receipt/document work. Some capabilities are documented or indexed but their full implementations were not sampled, so only evidenced relationships are drawn.
Main entry points: purchase_request_core.py Request API · services.py Approval workflow service · purchase_request.py Purchase domain models · po.py Purchase order generation
Components 20
Accounts & access
- JWT authentication
core/users/auth_views.py - Email auth serializer
core/users/auth_serializers.py - User management
core/users/views.py
Requests & approvals
- Purchase API routes
core/purches/urls.py - Request API
core/purches/views/purchase_request_core.py - Request serializer
core/purches/serializers/purchase_request.py - Approval endpoints
core/purches/views/approvals.py - Approval serializer
core/purches/serializers/approval.py - Approval workflow service
core/purches/services.py
Purchase orders
- Purchase domain models
core/purches/models/purchase_request.py - Purchase order generation
core/purches/po.py - Purchase order API
core/purches/views/purchase_order.py - Purchase order serializer
core/purches/serializers/purchase_order.py
Receipts & documents
- Receipt endpoints
core/purches/views/approvals_receipts.py - Receipt serializer
core/purches/serializers/receipt.py - Document endpoints
core/purches/views/documents.py - Document processing
core/purches/services.py
Other components
- Frontend client
- Application database
core/settings.py - Email delivery
Connections 21
- Frontend client → JWT authentication: requests tokens
- JWT authentication → Email auth serializer: validates credentials
core/users/auth_views.py - Frontend client → User management: uses account APIs
- User management → Email delivery: sends verification
core/users/views.py - Frontend client → Purchase API routes: calls purchase API
- Purchase API routes → Request API: routes requests
core/purches/urls.py - Request API → Request serializer: serializes requests
core/purches/views/purchase_request_core.py - Request serializer → Purchase domain models: creates request items
core/purches/serializers/purchase_request.py - Request API → Approval workflow service: invokes approval
core/purches/views/purchase_request_core.py - Approval endpoints → Approval serializer: uses serializer
core/purches/views/approvals.py - Approval endpoints → Purchase domain models: reads purchase state
core/purches/views/approvals.py - Approval workflow service → Purchase domain models: updates approvals
core/purches/services.py - Approval workflow service → Purchase order generation: creates purchase order
core/purches/services.py - Purchase order generation → Purchase domain models: reads request data
core/purches/po.py - Purchase order API → Purchase order serializer: serializes orders
core/purches/views/purchase_order.py - Receipt endpoints → Receipt serializer: serializes receipts
core/purches/views/approvals_receipts.py - Document endpoints → Document processing: uses processing service
core/purches/views/documents.py - Document processing → Purchase order generation: creates extracted order
core/purches/services.py - Request API → Application database: reads and writes
- Approval workflow service → Application database: persists decisions
- Receipt endpoints → Application database: reads receipts
core/purches/views/approvals_receipts.py