1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-07-21 13:47:39 +02:00
unleash.unleash/src/lib/openapi/spec/push-variants-schema.ts
Christopher Kolstad 53354224fc
chore: Bump biome and configure husky (#6589)
Upgrades biome to 1.6.1, and updates husky pre-commit hook.

Most changes here are making type imports explicit.
2024-03-18 13:58:05 +01:00

34 lines
1002 B
TypeScript

import { variantSchema } from './variant-schema';
import type { FromSchema } from 'json-schema-to-ts';
import { overrideSchema } from './override-schema';
export const pushVariantsSchema = {
$id: '#/components/schemas/pushVariantsSchema',
type: 'object',
description: 'Data used when copying variants into a new environment.',
properties: {
variants: {
type: 'array',
description: 'The variants to write to the provided environments',
items: {
$ref: '#/components/schemas/variantSchema',
},
},
environments: {
type: 'array',
description: 'The enviromnents to write the provided variants to',
items: {
type: 'string',
},
},
},
components: {
schemas: {
variantSchema,
overrideSchema,
},
},
} as const;
export type PushVariantsSchema = FromSchema<typeof pushVariantsSchema>;