openapi-codegen-typescript
Version:
OpenApi codegen for generating types an mocks from swagger json file
17 lines (16 loc) • 782 B
TypeScript
import { GetSchemasProps, SchemaProperties, SwaggerV2, SwaggerV3 } from './types';
export declare const getSchemaProperties: (objectProps: any) => SchemaProperties[];
/**
* Fetches swagger json file by provided url.
* @param url
*/
export declare const fetchSwaggerJsonFile: (url: string) => Promise<any>;
export declare const hashedString: (string: string) => number;
export declare function isSwaggerV3(json: SwaggerV2 | SwaggerV3): json is SwaggerV3;
export declare function isSwaggerV2(json: SwaggerV2 | SwaggerV3): json is SwaggerV2;
export declare const getSchemas: ({ json }: GetSchemasProps) => any;
export declare const writeToFile: ({ folderPath, fileName, resultString, }: {
folderPath: string;
fileName: string;
resultString: string;
}) => Promise<void>;