swagger-api / swagger-api/swagger-codegen
[typescript-fetch] need help to generate model using command line !
Nobody has claimed this yet.
- Dominant language
- Mustache
- Stars
- 17.8k
- Forks
- 6k
- PR merge metrics
- No merged PRs in 30d
Description
What is the correct command line to generate the typescript model outside my swagger.yaml file ?
If I execute the generator, I receive this error message :
Error (model name matches existing language type) cannot be used as a model name. Renamed to ModelError
Command Line :
java -jar -Dmodels e:\swagger-codegen-cli2.3.1.jar generate -l typescript-fetch -c E:\evs-via\evs-via-timeline-core\config\codegen-config.json -i E:\evs-via\evs-via-timeline-core\tmp\rest-api.yaml -o c:\temp\
Target project where I must use the generated models :
NodeJS
My project must auto generate the swagger model for language typescript using nodejs !
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start with the supplied Java command, codegen-config.json, and rest-api.yaml, then reproduce the typescript-fetch generation and inspect the model-name error. Done means identifying the correct command or configuration for generating models outside the Swagger definition and confirming it produces usable TypeScript models for the NodeJS project.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- java, node.js, typescript
- Domain
- tooling
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 25/100