Skip to content

Feature Flag Audit Report

This report audits all feature flags in infrastructure/flagsmith/configs/flags.json and segments in infrastructure/flagsmith/configs/segments.json.
Source version: flags.json 2.1.0. Generated: 2026-01.

Policy: We use Flagsmith even locally. Flag values come only from Flagsmith; there are no env-var overrides (e.g. no USE_ICEBERG_CATALOG, USE_P21_CUSTOM_SOURCE). Connection to Flagsmith uses FLAGSMITH_API_URL and FLAGSMITH_ENVIRONMENT_KEY (or FLAGSMITH_SERVER_KEY).


Flag Type Default What it gates
dagster_enabled boolean off Dagster-based data pipeline (replaces legacy sync). Webapp UI for sync cursors. Admin UI via Dagster+.
iceberg_catalog_enabled boolean on PostgreSQL-backed Iceberg catalog. Off = legacy filesystem metadata scanning.
Flag Type Default What it gates
netsuite_integration boolean off NetSuite ERP integration.
sap_b1_integration boolean off SAP Business One ERP integration.
odoo_integration boolean off Odoo ERP integration.
prophet21_integration boolean off Full Prophet21 V2 (custom source, version detection, DB access, tiered order creation). Off = legacy P21 OData-only orchestrator. Turn on experimentally first.
Flag Type Default What it gates
email_enabled boolean off All email: inbox, aliases, email-to-order.
email_body_extraction_enabled boolean off AI extraction of orders from email body (requires email_enabled).
Flag Type Default What it gates
pdf_extraction_v2 boolean off New PDF extraction pipeline.
use_mirascope_langfuse boolean off Mirascope @with_langfuse() for LLM tracing instead of manual Langfuse.
pdf_extraction_model multivariate gemini-2.5-flash Gemini model for PDF extraction (2.5-flash, 2.5-flash-lite, 2.5-pro, 3-flash-preview).
pdf_extraction_model_fallback string gemini-2.5-flash-lite Fallback model when primary fails or times out.
enhanced_ocr_preprocessing boolean off Enhanced OCR preprocessing for PDFs.
Flag Type Default What it gates
new_order_editor boolean off New React-based order editor.
order_totals_card_enabled boolean on Order totals summary card on order review page.
Flag Type Default What it gates
usage_billing_enabled boolean off Usage-based billing (line-item tracking, free trials, usage dashboard).
realtime_pricing boolean off Real-time pricing from ERP.
Flag Type Default What it gates
feature_flag_dashboard_enabled boolean off Feature flag dashboard in admin (internal).
sys_admin_panel_enabled boolean off Sys admin panel (billing config, org overrides, analytics).
Flag Type Default What it gates
unified_addresses boolean off Unified address model (billing + shipping).

Segment Description Rules
internal_team Boonetek internal (email domain or isInternalTeam) email CONTAINS @boonetek.com OR isInternalTeam = true
beta_users Opt-in beta betaEnabled = β€œtrue”
paid_orgs Paid subscriptions subscriptionTier IN [professional, enterprise]
enterprise_orgs Enterprise tier subscriptionTier = β€œenterprise”
org_boonetek Boonetek org (internal) organizationId = org_2YBxxxxxxx
early_adopters Early adopters organizationId IN [] (populate as needed)
pilot_customers Pilot customers organizationId IN [] (populate as needed)

To check that flags.json is synced to Development, Staging, and Production in Flagsmith:

Terminal window
cd infrastructure/flagsmith
op run --env-file=".env" -- python3 scripts/validate-flags-sync.py

Or with explicit credentials:

Terminal window
FLAGSMITH_API_URL=... FLAGSMITH_ADMIN_EMAIL=... FLAGSMITH_ADMIN_PASSWORD=... \
python3 scripts/validate-flags-sync.py

If any flag is missing in Flagsmith or in any environment, the script exits with status 1 and lists the gaps.
To fix: run scripts/import-flags.py (e.g. via the flagsmith-seed workflow or manually with --update), then re-run validate-flags-sync.py.


From _deprecated_flags in flags.json:

email_api_enabled, inbox_page_enabled, email_aliases_admin_enabled, email_processing_v2, dagster_pipeline_enabled, dagster_sync_v2, dagster_cursors_ui_enabled, typesense_search, typesense_search_enabled, typesense_search_fallback, document_upload_polling_enabled, batch_image_prefetch_enabled, pipeline_analysis_enabled.

Typesense flags retired: We use Typesense exclusively. typesense_search_enabled and typesense_search_fallback are deprecated; search always uses Typesense first and falls back to PostgreSQL on no results or error.