UNPKG

@apideck/portman

Version:

Port OpenAPI Spec to Postman Collection, with contract & variation tests included

26 lines (25 loc) 1.09 kB
import { OpenAPIV3 } from 'openapi-types'; import { OasMappedOperation } from './OasMappedOperation'; export interface OpenApiParserConfig { inputFile: string; ignoreCircularRefs?: boolean; } export interface IOpenApiParser { oas: OpenAPIV3.Document; mappedOperations: OasMappedOperation[]; operationIdMap: Record<string, OasMappedOperation>; getOperationById(operationId: string): OasMappedOperation | null; getOperationByPath(path: string): OasMappedOperation | null; } export declare class OpenApiParser { oas: OpenAPIV3.Document; mappedOperations: OasMappedOperation[]; operationIdMap: Record<string, OasMappedOperation>; convert(options: OpenApiParserConfig): Promise<OpenAPIV3.Document>; pathsToOperations: () => OasMappedOperation[]; mapOperationIds: () => void; getOperationById(operationId: string): OasMappedOperation | null; getOperationByPath(path: string): OasMappedOperation | null; getOperationsByIds(operationIds: string[]): OasMappedOperation[]; getOperationsByPath(path: string): OasMappedOperation[]; }