1.0.3 • Published 6 months ago

@types/openapi-sampler v1.0.3

Weekly downloads
1,035
License
MIT
Repository
github
Last release
6 months ago

Installation

npm install --save @types/openapi-sampler

Summary

This package contains type definitions for openapi-sampler (https://github.com/APIs-guru/openapi-sampler/).

Details

Files were exported from https://github.com/DefinitelyTyped/DefinitelyTyped/tree/master/types/openapi-sampler.

index.d.ts

// Type definitions for openapi-sampler 1.0
// Project: https://github.com/APIs-guru/openapi-sampler/
// Definitions by: Marcell Toth <https://github.com/marcelltoth>
// Definitions: https://github.com/DefinitelyTyped/DefinitelyTyped
// Minimum TypeScript Version: 3.0

export type OpenApiSchema = any;

export type OpenApiSpec = any;

export interface Options {
    /**
     * Don't include non-required object properties not specified in `required` property of the schema object
     */
    readonly skipNonRequired?: boolean | undefined;

    /**
     * Don't include readOnly object properties
     */
    readonly skipReadOnly?: boolean | undefined;

    /**
     * Don't include writeOnly object properties
     */
    readonly skipWriteOnly?: boolean | undefined;

    /**
     * Don't log console warning messages
     */
    readonly quiet?: boolean | undefined;
}

/**
 * Generates samples based on OpenAPI payload/response schema
 * @param schema A OpenAPI Schema Object
 * @param options Options
 * @param spec whole specification where the schema is taken from. Required only when schema may contain `$ref`. `spec` must not contain any external references.
 */
export function sample(schema: OpenApiSchema, options?: Options, spec?: OpenApiSpec): unknown;

Additional Details

  • Last updated: Thu, 08 Jul 2021 18:51:49 GMT
  • Dependencies: none
  • Global values: none

Credits

These definitions were written by Marcell Toth.

1.0.2

7 months ago

1.0.3

6 months ago

1.0.1

3 years ago

1.0.0

4 years ago