postman_collection 1.0.0 copy "postman_collection: ^1.0.0" to clipboard
postman_collection: ^1.0.0 copied to clipboard

Typed Dart models for Postman collections, generated from Postman's official v2.1.0 schema, and a converter from every Postman format to OpenAPI.

1.0.0 - 2026-10-06 #

Breaking rewrite. The package now lives in the api_spec_to_dart monorepo and is reinstated on pub.dev.

  • Typed models generated from the official schema. Every model is generated by swagger_to_dart from Postman's v2.1.0 collection JSON Schema (make models), replacing the hand-written 0.x models. Every "one of" in the schema is a sealed class (PostmanItems, PostmanRequest, PostmanUrl, PostmanDescription, …); unknown enum values decode to unknown. See the README for the full list.
  • Postman → OpenAPI converter (postmanToOpenApi) for v1, v2.0, v2.1, the Postman API envelope and v3 directories (package:postman_collection/io.dart), with normalizePostmanCollection, isPostmanCollection, postmanCollectionFromV3Files and inferJsonSchema.
  • No dio or retrofit dependency. The request-capture helpers moved to a dio interceptor recipe in the example.

Migrating from 0.x #

0.x 1.0.0
PostmanCollection PostmanCollection (item is List<PostmanItems>)
PostmanCollectionItem (request or folder) sealed PostmanItems: PostmanItemsItem(PostmanItem) or PostmanItemsItemGroup(PostmanItemGroup)
PostmanCollectionRequest sealed PostmanRequest: PostmanRequestObject(PostmanRequestObjectValue) or PostmanRequestString
PostmanCollectionRequestMode, PostmanFormDataEntry PostmanRequestObjectValueBody (mode: PostmanRequestObjectValueBodyMode), PostmanUrlEncodedParameter, sealed PostmanFormParameter
PostmanCollectionUrl sealed PostmanUrl (PostmanUrlObjectValue or a string)
PostmanCollectionResponse PostmanResponse
PostmanCollectionInfo, …Auth, …AuthAttribute, …AuthType, …Header, …QueryParam, …Variable, …VariableType, …Event, …Script, …Cookie, …Certificate, …ProxyConfig, …Version PostmanInfo, PostmanAuth, PostmanAuthAttribute, PostmanAuthType, PostmanHeader, PostmanQueryParam, PostmanVariable, PostmanVariableType, PostmanEvent, PostmanScript, PostmanCookie, PostmanCertificate, PostmanProxyConfig, PostmanVersion
PostmanCollectionCertificateSrc (a certificate's key and cert) PostmanCertificateKey and PostmanCertificateCert, each with src
PostmanCollectionDocumentationMixin, getRequestOptionsFromRetrofit, PostmanCollectionRequest.fromRequestOptions Removed: copy the PostmanRecorder interceptor from example/lib/src/dio_recipe.dart
toSentenceCase Removed

Fields the 0.x models added outside the schema (such as a response's postmanPreviewLanguage) are gone; the models hold exactly what the official schema defines.

0.1.0 #

  • Build with freezed 4 / json_serializable 6.14 and the latest Dart SDK (SDK floor ^3.9.0).
  • Breaking: freezed 3+ no longer generates map/when helpers — use Dart pattern matching (switch (mode) { PostmanCollectionRequestMode(...) => ... }).
  • Remove stray *.postman_collection.json outputs that were shipped inside lib/.
  • Fix the package test pointing at a non-existent fixture.

0.0.9 #

  • fix multipart formdata issue

0.0.8 #

  • Add support for multipart formdata

0.0.7 #

  • Read version from string for example 1.0.0
  • Read version from pubspec.yaml

0.0.6 #

  • Fix request body type

0.0.5 #

  • Fix query data type

0.0.4 #

  • Add request mode

0.0.3 #

  • Fix url in collection

0.0.2 #

  • Added new feature.
  • Fixed bug.
  • Add more documentation.

0.0.1 #

  • Initial version.
2
likes
160
points
206
downloads

Documentation

API reference

Publisher

unverified uploader

Weekly Downloads

Typed Dart models for Postman collections, generated from Postman's official v2.1.0 schema, and a converter from every Postman format to OpenAPI.

Repository (GitHub)
View/report issues
Contributing

Topics

#postman #openapi #codegen #dart

License

MIT (license)

Dependencies

freezed_annotation, json_annotation, yaml

More

Packages that depend on postman_collection