Skip to content

BUG: OAPI Codegen only generates the models that are present in an API YAML file. #1354

@driif

Description

@driif

After moving shared models into the 'Models' directory and generating APIs from folder paths, the shared models are not being utilized for generating Go structs. OAPI Codegen only generates the models that are present in an API YAML file. When a request or response utilizes a type from shared models, it generates this type in the following format:

type Response struct {
  Field *Struct {
    // Fields of shared models...
  }
}

However, it does not generate the actual model, which renders it impossible to use in the code.

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions