Data Layer low complexity backend
0
Dependencies
1
Dependents
0
Entities
0
Integrations

Description

Data access layer for the feature_flags table. Handles CRUD operations for organization-level feature flag records. Each row stores an organization foreign key, a feature key string, and a boolean enabled value.

Feature: Feature Toggles

feature-flags-repository

Responsibilities

  • Query all flags for a given organization ID
  • Upsert a single flag record by organization and key
  • Seed default flag rows when a new organization is provisioned
  • Fetch global default flag states from the system configuration
  • Bulk reset all flags for an organization to global defaults

Interfaces

findByOrganization(organizationId): FeatureFlag[]
upsert(organizationId, flagKey, enabled): FeatureFlag
seedDefaults(organizationId): void
getGlobalDefaults(): FeatureFlag[]
setGlobalDefault(flagKey, enabled): void
resetToDefaults(organizationId): void

Relationships

Dependents (1)

Components that depend on this component