import { ReferenceObject, SchemaObject } from '@nestjs/swagger/dist/interfaces/open-api-spec.interface'; import 'reflect-metadata'; import { IOptions } from './options'; /** * Either a plain JSON Schema object that gets merged into the existing schema, * or a function that receives as parameters the existing schema and global * options, returning an updated schema. */ export type DecoratorSchema = ReferenceObject | SchemaObject | ((source: SchemaObject, options: IOptions) => ReferenceObject | SchemaObject); /** * Supplement class or property with additional JSON Schema keywords. * * @param schema JSON Schema object that is merged into the schema derived from * class-validator decorators. In case of conflicts, keywords defined here * overwrite the existing ones. Alternatively you can supply a function that * receives as parameters the existing schema and global options, returning an * updated schema. */ export declare function JSONSchema(schema: DecoratorSchema): (target: object | Function, key?: string) => void; /** * Get the JSON Schema stored in given target's metadata. */ export declare function getMetadataSchema(target: object | Function, key: string): DecoratorSchema;