import fs from 'node:fs' import path from 'node:path' import {openapi} from '../server/app-contract.mjs' const destination=path.resolve('integration/openapi.json') fs.mkdirSync(path.dirname(destination),{recursive:true}) fs.writeFileSync(destination,JSON.stringify(openapi(),null,2)+'\n') console.log('Exported App API schema with '+Object.keys(openapi().paths).length+' paths')