Feature Flags Management
1. What does this feature do? (High-Level Overview)
Section titled “1. What does this feature do? (High-Level Overview)”Feature Flags Management lets Superadmins turn application features on or off without deploying new code. It provides a controlled way to release, test, or pause functionality in real time.
2. Who is this for? (Roles & Permissions)
Section titled “2. Who is this for? (Roles & Permissions)”- Superadmin: Can access the Feature Flags page, create flags, rename flags, toggle status, and delete flags.
- All other roles (including Admin): Cannot open this page in Admin View and cannot execute write actions from the UI flow.
3. Business Rules & Enforcements
Section titled “3. Business Rules & Enforcements”- Rule 1: Access to the Feature Flags screen in Admin View is restricted to users with the
SUPERADMINrole. - Rule 2: Creating a flag requires a non-empty
name, the name must be unique, and it cannot exceed 255 characters. - Rule 3: Toggling requires an existing flag name and an explicit enabled/disabled boolean value.
- Rule 4: Renaming requires a non-empty unique name (max 255 characters); updating to a duplicate name is rejected.
- Rule 5: Delete and rename actions fail with
Feature flag not foundif the target ID does not exist. - Rule 6: After create, toggle, rename, or delete, the backend clears the feature-flag cache so changes propagate immediately.
- Rule 7: The list is presented in alphabetical order by flag name.
4. UI Placement
Section titled “4. UI Placement”- Admin View > Site Administration > Feature Flags (
/settings/feature-flags) — Main management screen. - Feature Flags Management card in Site Administration — Entry point for Superadmins.
- Feature Flags table — Name, status (enabled/disabled), created date, and actions.
- Actions — Create new flag, toggle status, edit name, delete flag, and search/filter by name.
5. How-To Guide (Step-by-Step)
Section titled “5. How-To Guide (Step-by-Step)”Scenario A: Create and enable a new feature flag
- Open Admin View > Site Administration > Feature Flags.
- Click Create New Flag.
- Enter the flag name.
- Optionally enable Enable immediately.
- Click Create.
- Confirm the success message.
- If needed, use the toggle switch to change status after creation.
Scenario B: Rename or remove an existing flag
- In the Feature Flags list, find the target flag.
- To rename it, click the edit icon, enter the new name, and save.
- To remove it, click delete and confirm the warning dialog.
- Confirm the success message and verify the table refresh.
6. What happens if…? (Edge Cases / FAQ)
Section titled “6. What happens if…? (Edge Cases / FAQ)”-
Q: What happens if I try to create a flag with a name that already exists?
- A: The request is rejected by validation because flag names must be unique.
-
Q: What happens if I submit an empty flag name when creating or renaming?
- A: The UI blocks empty input, and the backend also rejects invalid payloads.
-
Q: Are changes immediate for users already in the app?
- A: Yes. After each write action, the feature-flag cache is flushed and the frontend reloads flags to apply the new state.