Typescript SDK is not getting generated
Closed this issue · 0 comments
creatorrr commented
Description:
We build our SDKs using the openapi.yaml
file. Unfortunately, the typescript SDK is not getting generated correctly for some reason. It may be related to a broken dependency but needs to be looked at.
Relevant file locations:
Steps to reproduce:
- Clone repo and
cd sdks/ts
directory. npm install
to install all dependencies.- Then run
npm run codegen
to start the code generation.
Error:
> @julep/sdk@0.3.3 openapi-codegen
> bash -c 'openapi -c axios --name JulepApiClient --useOptions --indent 2 -i <(yq "." ../../openapi.yaml) -o src/api --exportSchemas true --useUnionTypes true'
{
stack: 'SyntaxError: "/dev/fd/63" is not a valid JSON Schema\n' +
' at $RefParser.<anonymous> (/home/diwank/github.com/julep-ai/julep/sdks/ts/node_modules/@apidevtools/json-schema-ref-parser/dist/lib/index.js:126:37)\n' +
' at Generator.next (<anonymous>)\n' +
' at fulfilled (/home/diwank/github.com/julep-ai/julep/sdks/ts/node_modules/@apidevtools/json-schema-ref-parser/dist/lib/index.js:28:58)',
message: '"/dev/fd/63" is not a valid JSON Schema',
toJSON: [Function: toJSON],
name: 'SyntaxError',
toString: [Function: toString]
}