diff --git a/frontend/src/interfaces/uiConfig.ts b/frontend/src/interfaces/uiConfig.ts index 945d3addd5..111980f9ec 100644 --- a/frontend/src/interfaces/uiConfig.ts +++ b/frontend/src/interfaces/uiConfig.ts @@ -48,6 +48,7 @@ export interface IFlags { proPlanAutoCharge?: boolean; notifications?: boolean; loginHistory?: boolean; + projectScopedSegments?: boolean; } export interface IVersionInfo { diff --git a/src/lib/__snapshots__/create-config.test.ts.snap b/src/lib/__snapshots__/create-config.test.ts.snap index 2c650e6b8a..b649f742fb 100644 --- a/src/lib/__snapshots__/create-config.test.ts.snap +++ b/src/lib/__snapshots__/create-config.test.ts.snap @@ -80,6 +80,7 @@ exports[`should create default config 1`] = ` "newProjectOverview": false, "notifications": false, "proPlanAutoCharge": false, + "projectScopedSegments": false, "projectStatusApi": false, "proxyReturnAllToggles": false, "responseTimeWithAppNameKillSwitch": false, @@ -102,6 +103,7 @@ exports[`should create default config 1`] = ` "newProjectOverview": false, "notifications": false, "proPlanAutoCharge": false, + "projectScopedSegments": false, "projectStatusApi": false, "proxyReturnAllToggles": false, "responseTimeWithAppNameKillSwitch": false, diff --git a/src/lib/types/experimental.ts b/src/lib/types/experimental.ts index 2bafbb3fc1..9059dc55e6 100644 --- a/src/lib/types/experimental.ts +++ b/src/lib/types/experimental.ts @@ -64,6 +64,10 @@ const flags = { ), notifications: parseEnvVarBoolean(process.env.NOTIFICATIONS, false), loginHistory: parseEnvVarBoolean(process.env.UNLEASH_LOGIN_HISTORY, false), + projectScopedSegments: parseEnvVarBoolean( + process.env.PROJECT_SCOPED_SEGMENTS, + false, + ), }; export const defaultExperimentalOptions: IExperimentalOptions = { diff --git a/src/server-dev.ts b/src/server-dev.ts index 37541c0ea7..6a61b09663 100644 --- a/src/server-dev.ts +++ b/src/server-dev.ts @@ -42,6 +42,7 @@ process.nextTick(async () => { newProjectOverview: true, projectStatusApi: true, showProjectApiAccess: true, + projectScopedSegments: true, }, }, authentication: {