diff --git a/src/lib/openapi/spec/export-result-schema.ts b/src/lib/openapi/spec/export-result-schema.ts index d45e5a6165..a550898b79 100644 --- a/src/lib/openapi/spec/export-result-schema.ts +++ b/src/lib/openapi/spec/export-result-schema.ts @@ -5,6 +5,12 @@ import { featureEnvironmentSchema } from './feature-environment-schema'; import { contextFieldSchema } from './context-field-schema'; import { featureTagSchema } from './feature-tag-schema'; import { segmentSchema } from './segment-schema'; +import { parametersSchema } from './parameters-schema'; +import { legalValueSchema } from './legal-value-schema'; +import { variantSchema } from './variant-schema'; +import { overrideSchema } from './override-schema'; +import { variantsSchema } from './variants-schema'; +import { constraintSchema } from './constraint-schema'; export const exportResultSchema = { $id: '#/components/schemas/exportResultSchema', @@ -57,6 +63,12 @@ export const exportResultSchema = { contextFieldSchema, featureTagSchema, segmentSchema, + variantsSchema, + variantSchema, + overrideSchema, + constraintSchema, + parametersSchema, + legalValueSchema, }, }, } as const; diff --git a/src/lib/openapi/spec/feature-environment-schema.ts b/src/lib/openapi/spec/feature-environment-schema.ts index 30f95138e9..b68249e48c 100644 --- a/src/lib/openapi/spec/feature-environment-schema.ts +++ b/src/lib/openapi/spec/feature-environment-schema.ts @@ -12,6 +12,9 @@ export const featureEnvironmentSchema = { name: { type: 'string', }, + featureName: { + type: 'string', + }, environment: { type: 'string', }, diff --git a/src/lib/openapi/spec/feature-strategy-schema.ts b/src/lib/openapi/spec/feature-strategy-schema.ts index 168cfba2bb..cb26805dcb 100644 --- a/src/lib/openapi/spec/feature-strategy-schema.ts +++ b/src/lib/openapi/spec/feature-strategy-schema.ts @@ -14,6 +14,9 @@ export const featureStrategySchema = { name: { type: 'string', }, + featureName: { + type: 'string', + }, sortOrder: { type: 'number', }, diff --git a/src/lib/types/model.ts b/src/lib/types/model.ts index 1c75c894be..fd967de7ac 100644 --- a/src/lib/types/model.ts +++ b/src/lib/types/model.ts @@ -21,6 +21,7 @@ export enum WeightType { export interface IStrategyConfig { id?: string; name: string; + featureName?: string; constraints?: IConstraint[]; segments?: number[]; parameters?: { [key: string]: string }; diff --git a/src/test/e2e/api/openapi/__snapshots__/openapi.e2e.test.ts.snap b/src/test/e2e/api/openapi/__snapshots__/openapi.e2e.test.ts.snap index b63cebc297..15981b2367 100644 --- a/src/test/e2e/api/openapi/__snapshots__/openapi.e2e.test.ts.snap +++ b/src/test/e2e/api/openapi/__snapshots__/openapi.e2e.test.ts.snap @@ -1143,6 +1143,9 @@ exports[`should serve the OpenAPI spec 1`] = ` "environment": { "type": "string", }, + "featureName": { + "type": "string", + }, "name": { "type": "string", }, @@ -1285,6 +1288,9 @@ exports[`should serve the OpenAPI spec 1`] = ` }, "type": "array", }, + "featureName": { + "type": "string", + }, "id": { "type": "string", },