diff --git a/frontend/src/openapi/models/bulkMetricsSchema.ts b/frontend/src/openapi/models/bulkMetricsSchema.ts index 75953da92f..497ef17e3a 100644 --- a/frontend/src/openapi/models/bulkMetricsSchema.ts +++ b/frontend/src/openapi/models/bulkMetricsSchema.ts @@ -4,6 +4,7 @@ * See `gen:api` script in package.json */ import type { BulkRegistrationSchema } from './bulkRegistrationSchema.js'; +import type { ImpactMetricsSchema } from './impactMetricsSchema.js'; import type { ClientMetricsEnvSchema } from './clientMetricsEnvSchema.js'; /** @@ -12,6 +13,8 @@ import type { ClientMetricsEnvSchema } from './clientMetricsEnvSchema.js'; export interface BulkMetricsSchema { /** A list of applications registered by an Unleash SDK */ applications: BulkRegistrationSchema[]; + /** a list of custom impact metrics registered by downstream providers. (Typically Unleash Edge) */ + impactMetrics?: ImpactMetricsSchema[]; /** a list of client usage metrics registered by downstream providers. (Typically Unleash Edge) */ metrics: ClientMetricsEnvSchema[]; } diff --git a/frontend/src/openapi/models/changeRequestAvailableReviewersSchema.ts b/frontend/src/openapi/models/changeRequestAvailableReviewersSchema.ts new file mode 100644 index 0000000000..4677c8cc97 --- /dev/null +++ b/frontend/src/openapi/models/changeRequestAvailableReviewersSchema.ts @@ -0,0 +1,14 @@ +/** + * Generated by Orval + * Do not edit manually. + * See `gen:api` script in package.json + */ +import type { ChangeRequestReviewerSchema } from './changeRequestReviewerSchema.js'; + +/** + * A list of users available to review a change request. + */ +export interface ChangeRequestAvailableReviewersSchema { + /** a list of reviewers */ + reviewers: ChangeRequestReviewerSchema[]; +} diff --git a/frontend/src/openapi/models/changeRequestReviewerSchema.ts b/frontend/src/openapi/models/changeRequestReviewerSchema.ts new file mode 100644 index 0000000000..45e517684a --- /dev/null +++ b/frontend/src/openapi/models/changeRequestReviewerSchema.ts @@ -0,0 +1,30 @@ +/** + * Generated by Orval + * Do not edit manually. + * See `gen:api` script in package.json + */ + +/** + * Information about a user available to review a change request + */ +export interface ChangeRequestReviewerSchema { + /** The email of the approving user */ + email: string; + /** Id of the user available to review */ + id: number; + /** + * The URL where the user's image can be found. + * @nullable + */ + imageUrl?: string | null; + /** + * The name of the approving user + * @nullable + */ + name?: string | null; + /** + * The username of the approving user + * @nullable + */ + username?: string | null; +} diff --git a/frontend/src/openapi/models/changeRequestSetApproversSchema.ts b/frontend/src/openapi/models/changeRequestSetApproversSchema.ts new file mode 100644 index 0000000000..9a0e48b025 --- /dev/null +++ b/frontend/src/openapi/models/changeRequestSetApproversSchema.ts @@ -0,0 +1,13 @@ +/** + * Generated by Orval + * Do not edit manually. + * See `gen:api` script in package.json + */ + +/** + * Data used to update a [change request](https://docs.getunleash.io/reference/change-requests)'s requested approvers. + */ +export interface ChangeRequestSetApproversSchema { + /** An array of user ids to request approval from. This will replace the current approvers. */ + reviewers: number[]; +} diff --git a/frontend/src/openapi/models/createApplicationSchema.ts b/frontend/src/openapi/models/createApplicationSchema.ts index f2b129bec2..a45f8326cf 100644 --- a/frontend/src/openapi/models/createApplicationSchema.ts +++ b/frontend/src/openapi/models/createApplicationSchema.ts @@ -8,14 +8,10 @@ * Reported application information from Unleash SDKs */ export interface CreateApplicationSchema { - /** Name of the application */ - appName?: string; /** Css color to be used to color the application's entry in the application list */ color?: string; /** An URL to an icon file to be used for the applications's entry in the application list */ icon?: string; - /** Which SDK and version the application reporting uses. Typically represented as `:` */ - sdkVersion?: string; /** Which [strategies](https://docs.getunleash.io/topics/the-anatomy-of-unleash#activation-strategies) the application has loaded. Useful when trying to figure out if your [custom strategy](https://docs.getunleash.io/reference/custom-activation-strategies) has been loaded in the SDK */ strategies?: string[]; /** A link to reference the application reporting the metrics. Could for instance be a GitHub link to the repository of the application */ diff --git a/frontend/src/openapi/models/eventSchema.ts b/frontend/src/openapi/models/eventSchema.ts index 47e2cdf9f6..10649c5438 100644 --- a/frontend/src/openapi/models/eventSchema.ts +++ b/frontend/src/openapi/models/eventSchema.ts @@ -36,6 +36,10 @@ export interface EventSchema { * @nullable */ featureName?: string | null; + /** The unique identifier for the transaction group this event belongs to, if applicable. */ + groupId?: string; + /** The type of transaction group this event belongs to, if applicable. */ + groupType?: string; /** * The ID of the event. An increasing natural number. * @minimum 1 @@ -46,10 +50,6 @@ export interface EventSchema { * @nullable */ ip?: string | null; - /** - * The event group ID. - */ - groupId?: string; /** * The concise, human-readable name of the event. * @nullable diff --git a/frontend/src/openapi/models/eventSchemaType.ts b/frontend/src/openapi/models/eventSchemaType.ts index 4e99796a5c..fff6f60771 100644 --- a/frontend/src/openapi/models/eventSchemaType.ts +++ b/frontend/src/openapi/models/eventSchemaType.ts @@ -174,4 +174,6 @@ export const EventSchemaType = { 'scim-users-deleted': 'scim-users-deleted', 'scim-groups-deleted': 'scim-groups-deleted', 'cdn-token-created': 'cdn-token-created', + 'change-request-requested-approvers-updated': + 'change-request-requested-approvers-updated', } as const; diff --git a/frontend/src/openapi/models/impactMetricsSchema.ts b/frontend/src/openapi/models/impactMetricsSchema.ts new file mode 100644 index 0000000000..0fb5833c4a --- /dev/null +++ b/frontend/src/openapi/models/impactMetricsSchema.ts @@ -0,0 +1,21 @@ +/** + * Generated by Orval + * Do not edit manually. + * See `gen:api` script in package.json + */ +import type { ImpactMetricsSchemaSamplesItem } from './impactMetricsSchemaSamplesItem.js'; +import type { ImpactMetricsSchemaType } from './impactMetricsSchemaType.js'; + +/** + * Used for reporting impact metrics from SDKs + */ +export interface ImpactMetricsSchema { + /** Human-readable description of what the metric measures */ + help: string; + /** Name of the impact metric */ + name: string; + /** Samples of the metric */ + samples: ImpactMetricsSchemaSamplesItem[]; + /** Type of the metric */ + type: ImpactMetricsSchemaType; +} diff --git a/frontend/src/openapi/models/impactMetricsSchemaSamplesItem.ts b/frontend/src/openapi/models/impactMetricsSchemaSamplesItem.ts new file mode 100644 index 0000000000..f801cf4499 --- /dev/null +++ b/frontend/src/openapi/models/impactMetricsSchemaSamplesItem.ts @@ -0,0 +1,16 @@ +/** + * Generated by Orval + * Do not edit manually. + * See `gen:api` script in package.json + */ +import type { ImpactMetricsSchemaSamplesItemLabels } from './impactMetricsSchemaSamplesItemLabels.js'; + +/** + * A sample of a metric with a value and optional labels + */ +export type ImpactMetricsSchemaSamplesItem = { + /** Optional labels for the metric sample */ + labels?: ImpactMetricsSchemaSamplesItemLabels; + /** The value of the metric sample */ + value: number; +}; diff --git a/frontend/src/openapi/models/impactMetricsSchemaSamplesItemLabels.ts b/frontend/src/openapi/models/impactMetricsSchemaSamplesItemLabels.ts new file mode 100644 index 0000000000..415e6d8de3 --- /dev/null +++ b/frontend/src/openapi/models/impactMetricsSchemaSamplesItemLabels.ts @@ -0,0 +1,10 @@ +/** + * Generated by Orval + * Do not edit manually. + * See `gen:api` script in package.json + */ + +/** + * Optional labels for the metric sample + */ +export type ImpactMetricsSchemaSamplesItemLabels = { [key: string]: string }; diff --git a/frontend/src/openapi/models/impactMetricsSchemaType.ts b/frontend/src/openapi/models/impactMetricsSchemaType.ts new file mode 100644 index 0000000000..c349692b90 --- /dev/null +++ b/frontend/src/openapi/models/impactMetricsSchemaType.ts @@ -0,0 +1,17 @@ +/** + * Generated by Orval + * Do not edit manually. + * See `gen:api` script in package.json + */ + +/** + * Type of the metric + */ +export type ImpactMetricsSchemaType = + (typeof ImpactMetricsSchemaType)[keyof typeof ImpactMetricsSchemaType]; + +// eslint-disable-next-line @typescript-eslint/no-redeclare +export const ImpactMetricsSchemaType = { + counter: 'counter', + gauge: 'gauge', +} as const; diff --git a/frontend/src/openapi/models/index.ts b/frontend/src/openapi/models/index.ts index b07a6705e0..3d3d38d720 100644 --- a/frontend/src/openapi/models/index.ts +++ b/frontend/src/openapi/models/index.ts @@ -152,6 +152,7 @@ export * from './changeProjectSchema.js'; export * from './changeRequestAddCommentSchema.js'; export * from './changeRequestApprovalSchema.js'; export * from './changeRequestApprovalSchemaCreatedBy.js'; +export * from './changeRequestAvailableReviewersSchema.js'; export * from './changeRequestChangeSchema.js'; export * from './changeRequestChangeSchemaCreatedBy.js'; export * from './changeRequestChangeSchemaPayload.js'; @@ -270,6 +271,7 @@ export * from './changeRequestOneOrManyCreateSchemaOneOfTwosevenAction.js'; export * from './changeRequestOneOrManyCreateSchemaOneOfTwothree.js'; export * from './changeRequestOneOrManyCreateSchemaOneOfTwothreeAction.js'; export * from './changeRequestPlaygroundRequestSchema.js'; +export * from './changeRequestReviewerSchema.js'; export * from './changeRequestScheduleSchema.js'; export * from './changeRequestScheduleSchemaOneOf.js'; export * from './changeRequestScheduleSchemaOneOfFive.js'; @@ -293,6 +295,7 @@ export * from './changeRequestSegmentChangeSchema.js'; export * from './changeRequestSegmentChangeSchemaCreatedBy.js'; export * from './changeRequestSegmentChangeSchemaPayload.js'; export * from './changeRequestSegmentChangeSchemaPayloadOneOf.js'; +export * from './changeRequestSetApproversSchema.js'; export * from './changeRequestStateSchema.js'; export * from './changeRequestStateSchemaOneOf.js'; export * from './changeRequestStateSchemaOneOfState.js'; @@ -873,6 +876,10 @@ export * from './healthReportSchema.js'; export * from './healthReportSchemaMode.js'; export * from './idSchema.js'; export * from './idsSchema.js'; +export * from './impactMetricsSchema.js'; +export * from './impactMetricsSchemaSamplesItem.js'; +export * from './impactMetricsSchemaSamplesItemLabels.js'; +export * from './impactMetricsSchemaType.js'; export * from './importToggles404.js'; export * from './importTogglesSchema.js'; export * from './importTogglesValidateItemSchema.js'; @@ -889,6 +896,7 @@ export * from './instanceAdminStatsSchemaProductionChanges.js'; export * from './instanceInsightsSchema.js'; export * from './instanceInsightsSchemaEnvironmentTypeTrendsItem.js'; export * from './instanceInsightsSchemaFlagTrendsItem.js'; +export * from './instanceInsightsSchemaLifecycleTrendsItem.js'; export * from './instanceInsightsSchemaMetricsSummaryTrendsItem.js'; export * from './instanceInsightsSchemaProjectFlagTrendsItem.js'; export * from './instanceInsightsSchemaUserTrendsItem.js'; @@ -1338,7 +1346,6 @@ export * from './uncomplete401.js'; export * from './uncomplete403.js'; export * from './uncomplete404.js'; export * from './unknownFlagSchema.js'; -export * from './unknownFlagSchemaReportedByItem.js'; export * from './unknownFlagsResponseSchema.js'; export * from './unsubscribeEmailSubscription401.js'; export * from './unsubscribeEmailSubscription404.js'; diff --git a/frontend/src/openapi/models/instanceInsightsSchema.ts b/frontend/src/openapi/models/instanceInsightsSchema.ts index 640816e7d2..e9559ac035 100644 --- a/frontend/src/openapi/models/instanceInsightsSchema.ts +++ b/frontend/src/openapi/models/instanceInsightsSchema.ts @@ -5,6 +5,7 @@ */ import type { InstanceInsightsSchemaEnvironmentTypeTrendsItem } from './instanceInsightsSchemaEnvironmentTypeTrendsItem.js'; import type { InstanceInsightsSchemaFlagTrendsItem } from './instanceInsightsSchemaFlagTrendsItem.js'; +import type { InstanceInsightsSchemaLifecycleTrendsItem } from './instanceInsightsSchemaLifecycleTrendsItem.js'; import type { InstanceInsightsSchemaMetricsSummaryTrendsItem } from './instanceInsightsSchemaMetricsSummaryTrendsItem.js'; import type { InstanceInsightsSchemaProjectFlagTrendsItem } from './instanceInsightsSchemaProjectFlagTrendsItem.js'; import type { InstanceInsightsSchemaUserTrendsItem } from './instanceInsightsSchemaUserTrendsItem.js'; @@ -17,6 +18,8 @@ export interface InstanceInsightsSchema { environmentTypeTrends: InstanceInsightsSchemaEnvironmentTypeTrendsItem[]; /** How number of flags changed over time */ flagTrends: InstanceInsightsSchemaFlagTrendsItem[]; + /** Weekly count of new flags entering production */ + lifecycleTrends: InstanceInsightsSchemaLifecycleTrendsItem[]; /** How metrics data per project changed over time */ metricsSummaryTrends: InstanceInsightsSchemaMetricsSummaryTrendsItem[]; /** How number of flags per project changed over time */ diff --git a/frontend/src/openapi/models/instanceInsightsSchemaLifecycleTrendsItem.ts b/frontend/src/openapi/models/instanceInsightsSchemaLifecycleTrendsItem.ts new file mode 100644 index 0000000000..8ec7ed8828 --- /dev/null +++ b/frontend/src/openapi/models/instanceInsightsSchemaLifecycleTrendsItem.ts @@ -0,0 +1,16 @@ +/** + * Generated by Orval + * Do not edit manually. + * See `gen:api` script in package.json + */ + +export type InstanceInsightsSchemaLifecycleTrendsItem = { + /** A UTC date when the stats were captured. Time is the very end of a given week. */ + date: string; + /** Number of flags that entered production during this week */ + newProductionFlags: number; + /** Project id that the flags belong to */ + project?: string; + /** Year and week in a given year for which the stats were calculated */ + week: string; +}; diff --git a/frontend/src/openapi/models/searchEventsParams.ts b/frontend/src/openapi/models/searchEventsParams.ts index 5f135c0a99..028f9ad7d9 100644 --- a/frontend/src/openapi/models/searchEventsParams.ts +++ b/frontend/src/openapi/models/searchEventsParams.ts @@ -9,6 +9,14 @@ export type SearchEventsParams = { * Find events by a free-text search query. The query will be matched against the event data payload (if any). */ query?: string; + /** + * Filter by event ID using supported operators: IS, IS_ANY_OF. + */ + id?: string; + /** + * Filter by group ID using supported operators: IS, IS_ANY_OF. + */ + groupId?: string; /** * Filter by feature name using supported operators: IS, IS_ANY_OF */ diff --git a/frontend/src/openapi/models/unknownFlagSchema.ts b/frontend/src/openapi/models/unknownFlagSchema.ts index 1b972d15a1..7f20b818b8 100644 --- a/frontend/src/openapi/models/unknownFlagSchema.ts +++ b/frontend/src/openapi/models/unknownFlagSchema.ts @@ -3,14 +3,17 @@ * Do not edit manually. * See `gen:api` script in package.json */ -import type { UnknownFlagSchemaReportedByItem } from './unknownFlagSchemaReportedByItem.js'; /** * An unknown flag that has been reported by the system */ export interface UnknownFlagSchema { + /** The name of the application that reported the unknown flag. */ + appName: string; + /** The environment in which the unknown flag was reported. */ + environment: string; /** The name of the unknown flag. */ name: string; - /** Details about the application that reported the unknown flag. */ - reportedBy: UnknownFlagSchemaReportedByItem[]; + /** The date and time when the unknown flag was reported. */ + seenAt: string; } diff --git a/frontend/src/openapi/models/unknownFlagSchemaReportedByItem.ts b/frontend/src/openapi/models/unknownFlagSchemaReportedByItem.ts deleted file mode 100644 index ec1f7c4e05..0000000000 --- a/frontend/src/openapi/models/unknownFlagSchemaReportedByItem.ts +++ /dev/null @@ -1,12 +0,0 @@ -/** - * Generated by Orval - * Do not edit manually. - * See `gen:api` script in package.json - */ - -export type UnknownFlagSchemaReportedByItem = { - /** The name of the application that reported the unknown flag. */ - appName: string; - /** The date and time when the unknown flag was reported. */ - seenAt: string; -};