Documentation Overview

All documentation pages organized by domain. Use the sidebar for persistent navigation or browse by section below.


Core Infrastructure

Core

Base models, validators, fields, caching, and utilities shared across all domains.

PageDescription
OverviewBase models, mixins, revision tracking
ModelsSanityIntegratedModel, SoftDeleteMixin, base mixins
ValidatorsInput sanitizers and validation classes
FieldsEncryptedJSONField and custom field types
UtilitiesEncryption, performance logging, and analytics helpers
CachingRedis-backed DRF response caching and invalidation
ExceptionsSecure error handling and exception classes
AdminEditorial Sanity widgets, sync-health mixins, deletion guard
ExamplesUsage examples

Integrations

Bidirectional Sanity CMS sync, webhook processing, and reference resolution.

PageDescription
OverviewSync architecture and webhook pipeline
ModelsWebhookEvent, SyncAuditLog, OutboundMutationLog
AdaptersDomain sync adapters
SerializersSync serializers
ServicesSync utilities and helpers
ValidatorsOutbound reference-shape validator and schema-to-data parity classifier
SignalsSync signal handlers
TasksCelery webhook processing pipeline
ViewsWebhook endpoints
Reference ResolverResolves Sanity _ref references to Django foreign keys
Sync ContextThread-local loop prevention for bidirectional sync
Reference LogicDomain-specific reference resolution patterns
ExamplesIntegration examples

Business Domains

Users

User management, authentication flows, and role-based access control.

PageDescription
OverviewDomain overview and quick links
ModelsUser, Employee, Customer, Manager, VIP, Influencer
AuthenticationEmail/password and PIN authentication
PermissionsRole-based access control
SerializersUser API serializers
ServicesUser service layer
SignalsRole sync signals
ViewsUser endpoints
Analytics ServiceCustomer and employee analytics aggregation
BackendsToken authentication backend
ExamplesUsage examples

Products

Product catalog, variants, inventory, and Elasticsearch search.

PageDescription
OverviewDomain overview and quick links
ModelsProduct, ProductVariant, InventoryLevel
SerializersProduct API serializers
ServicesProduct service layer
SignalsVariant sync signals
ViewsProduct endpoints with caching
SearchElasticsearch integration
Smart FiltersDynamic filter availability and smart aggregations
TasksCelery tasks for manifests, snapshots, and inventory reconcile
Analytics ServiceInventory analytics aggregation and trends
ExamplesUsage examples

Stores

Multi-location store management, tax jurisdictions, and operating hours.

PageDescription
OverviewDomain overview and quick links
ModelsStore, TaxJurisdiction, ComplianceCheck
SerializersStore API serializers
ServicesStore service layer
SignalsStore cache invalidation
ViewsStore endpoints
Dashboard HomeDashboard home KPIs, top products, low stock alerts
ExamplesUsage examples

Zones

Zone-based inventory assignment, planograms, and par levels.

PageDescription
OverviewDomain overview and quick links
ModelsZone, ZoneInventory, ParLevel, Planogram
SerializersZone API serializers
ServicesZoneAssignmentService
SignalsZone cache invalidation
ViewsZone endpoints
ExamplesUsage examples

Transactions

POS transaction lifecycle, returns, store credit, and cash drawer management.

PageDescription
OverviewDomain overview and quick links
ModelsSaleTransaction, Return, StoreCredit, CashDrawer
SerializersTransaction API serializers
ServicesTransaction, return, and cash drawer services
SignalsTransaction lifecycle signals
ViewsTransaction endpoints
PickupPickup scheduling, lifecycle, and management
Analytics Pre-AggregationDaily revenue and inventory summary tables, Celery rollup tasks
ExamplesUsage examples

Payments

Payment processing, refunds, and processor webhook handling.

PageDescription
OverviewDomain overview and quick links
ModelsPayment, PaymentMethod, PaymentProcessor, Refund
SerializersPayment API serializers
ServicesPayment processing service
SignalsPayment automation
ViewsPayment endpoints
WebhooksPayment processor webhook handling
ExamplesUsage examples

Promotions

Promotional campaigns, discount codes, and A/B testing.

PageDescription
OverviewDomain overview and quick links
ModelsPromotionalCampaign, PromoCode, ABTest
SerializersPromotion API serializers
ServicesDiscount calculation and campaign service
SignalsCache invalidation and sync signals
ViewsPromotion endpoints
ExamplesUsage examples

Compliance

Industry-agnostic compliance scaffold: age verification, tax classification, purchase limits, regulated customer onboarding, KYC vendor integration, compliance reports, and Metrc state track integration.

PageDescription
OverviewArchitecture, profile model accessors, endpoint summary
ModelsAbstract bases, cannabis concrete models, ComplianceReport
ServicesAge verification, tax classification, employee gate, onboarding, report orchestration, purchase limits, recall
SignalsProfile sync, return snapshots, Metrc tag sync, destruction events
ViewsPurchase limits, age verification, onboarding, pending-credential review, KYC webhook, reports
AdaptersKYCVendorAdapter base, VerificationResult, PersonaAdapter
WebhooksPersona HMAC-signed webhook with signature verification and state gating
ValidatorsPermit and credential payload validators, dispatcher
Utilitiescredential_utils and permit_utils lookups

Procurement

Supplier and purchase-order management: Sanity-synced suppliers and POs, compliance verification slot, receiving-driven inventory updates, and reorder-level monitoring.

PageDescription
OverviewOwnership model, endpoint summary, Sanity integration
ModelsSupplier, PurchaseOrder (status machine, compliance_verification), PurchaseOrderLineItem
SerializersSanity ref resolution, compliance-verification handling
ViewsSupplier and purchase-order endpoints
SignalsOutbound sync, status snapshots, receiving-driven inventory updates, PO total-cost maintenance
TasksReorder-level checks (daily), alerting
Analytics ServiceProcurement summary, supplier performance, lead-time performance
ExamplesUsage examples

Cash Management

Cashier shift tracking and physical drawer-count reconciliation. No HTTP API surface; models only.

PageDescription
OverviewDomain overview and ownership model
ModelsCashierShift, DrawerCount

Advanced Operations

POS Gateway

Real-time POS terminal integration via WebSockets.

PageDescription
OverviewDomain overview and quick links
ModelsTerminalSession, InventoryReservation
AuthenticationJWT-based terminal authentication
ConsumersWebSocket consumer classes
SerializersPOS API serializers
ServicesGateway service layer
SignalsTerminal event signals
ViewsPOS REST endpoints
BroadcastWebSocketBroadcaster and channel management
InfrastructureApp config, URL routing, and deployment
ExamplesUsage examples

Tasks

Task management, delivery scheduling, and notifications.

PageDescription
OverviewDomain overview and quick links
ModelsTask, DeliverySchedule
SerializersTask API serializers
ServicesTask service layer
SignalsNotification signals
ViewsTask endpoints
ExamplesUsage examples

Web Auth

Web authentication, session management, and security middleware.

PageDescription
OverviewDomain overview and quick links
ModelsAuth session models
AuthenticationAuthentication backends
MiddlewareSecurity middleware
SerializersAuth serializers
ServicesAuth services
SignalsSession lifecycle signals
ViewsAuth endpoints
ExamplesUsage examples

Web Commerce

Web checkout, cart management, guest sessions, and reservations.

PageDescription
OverviewDomain overview and quick links
ModelsCheckoutSession, ReservationContext
SerializersCheckout flow serializers
ServicesCart, checkout, and reservation services
MiddlewareCart validation and session middleware
SignalsCheckout lifecycle event handlers
TasksPeriodic cleanup and maintenance tasks
ViewsCommerce API endpoints

Analytics

Composed dashboard endpoints that aggregate data from multiple domains into unified page payloads.

PageDescription
OverviewArchitecture, response envelope, query parameters
ViewsAll 12 analytics endpoints — Commerce, Operations, People, Growth, System
ServicesActiveOperationsService, InfrastructureService

Sanity Studio

Content editing workflows for the Sanity CMS.

PageDescription
OverviewContent types, sync flow, field transformation reference
ProductsProduct creation and organization
Product VariantsVariant creation with attributes and pricing
Product AttributesAttribute type definitions and values
Inventory LevelsPer-store stock management
PlanogramsVisual merchandising blueprints
StoresStore setup with operating hours and configuration
UsersUser management with five role types
Promo CodesDiscount code configuration
CampaignsCampaign coordination and targeting
A/B TestsSplit testing configuration and results

Was this page helpful?