( files: HttpImportFile[], )
| 40 | } |
| 41 | |
| 42 | export async function parseHttpImportFiles( |
| 43 | files: HttpImportFile[], |
| 44 | ): Promise<HttpImportResult> { |
| 45 | const expandedFiles = await expandZipFiles(files) |
| 46 | const postman = parsePostmanFiles(expandedFiles) |
| 47 | const openCollection = parseOpenCollectionFiles(expandedFiles) |
| 48 | const openApi = parseOpenApiFiles(expandedFiles) |
| 49 | |
| 50 | return { |
| 51 | collections: [ |
| 52 | ...postman.collections, |
| 53 | ...openCollection.collections, |
| 54 | ...openApi.collections, |
| 55 | ], |
| 56 | environments: [ |
| 57 | ...postman.environments, |
| 58 | ...openCollection.environments, |
| 59 | ...openApi.environments, |
| 60 | ], |
| 61 | warnings: [ |
| 62 | ...postman.warnings, |
| 63 | ...openCollection.warnings, |
| 64 | ...openApi.warnings, |
| 65 | ], |
| 66 | } |
| 67 | } |
| 68 | |
| 69 | export type { |
| 70 | HttpImportFile, |
no test coverage detected