swagger_parser 1.18.3 copy "swagger_parser: ^1.18.3" to clipboard
swagger_parser: ^1.18.3 copied to clipboard

Package that generates REST clients and data classes from OpenApi definition file

example/README.md

  • Put your schema file from swagger and add the path to it in pubspec.yaml #

  • Set the output directory in pubspec.yaml #

  • Run command below to generate rest clients and data classes: #

dart run swagger_parser
  • For freezed with retrofit use build.yaml file with this content: #

global_options:
  freezed:
    runs_before:
      - json_serializable
  json_serializable:
    runs_before:
      - retrofit_generator
  • Run code generation with build_runner for json_seializable(freezed) and retrofit with command: #

dart run build_runner build
  • Clients and models are generated! #

85
likes
0
pub points
80%
popularity

Publisher

verified publishercarapacik.dev

Package that generates REST clients and data classes from OpenApi definition file

Repository (GitHub)
View/report issues

Topics

#swagger #openapi #codegen #api #rest

License

unknown (license)

Dependencies

args, collection, meta, path, yaml

More

Packages that depend on swagger_parser