OpenAPITools / OpenAPITools/openapi-generator

[REQ] Expose "fullyResolve" & "flatten" of the "swagger-parser" to CLI

Open
#11,831 1 comment 6 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Enhancement: Feature
Dominant language
Java
Stars
26.8k
Forks
7.7k
PR merge metrics
PR metrics pending

Description

Is your feature request related to a problem? Please describe.
  • "Normalizing" models with $ref is good reuse practice

  • "Denormalizing" model / parameters makes them more readable.

  • One implementation can be represented as many different models.

  • "resolveFully" can noramlize a model to be much better compared.

Describe the solution you'd like

The Swagger-Parser has three nice options:

  1. setResolveFully
  2. flatten
  3. resolveCombinators

Exposing this transformations as possible "preprocessing" parameters should be cheap "IMHO" :-).

Describe alternatives you've considered

  • Post-Processesing the ".json" with an external tool to resolve the internal references.

Additional context

  • Love the "openapi-generator" product anyhow.

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

The issue names no files or tests. Start by locating the CLI preprocessing-parameter handling and the Swagger-Parser integration, then determine how setResolveFully, flatten, and resolveCombinators can be exposed. Done means these transformations are available as CLI preprocessing options and are covered by relevant tests.

Written by the indexing model from the issue text.

Assessment

Tech stack
java, openapi
Domain
api, cli
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.