Skip to content

Feature: Add support for importing Postman environment files#359

Open
Abiggj wants to merge 1 commit into
darrenburns:mainfrom
Abiggj:feature/issue-270
Open

Feature: Add support for importing Postman environment files#359
Abiggj wants to merge 1 commit into
darrenburns:mainfrom
Abiggj:feature/issue-270

Conversation

@Abiggj

@Abiggj Abiggj commented Jun 25, 2026

Copy link
Copy Markdown

Description

This PR adds native support for importing Postman environment JSON files directly to posting's import command, resolves issue #270 . Currently, when users import a Postman collection, only variables defined directly within the collection file are extracted. With this change, users can now import their separate Postman environment export files.

Key Changes

  1. Environment Parser Integration:
    • Added import_postman_env function to src/posting/importing/postman.py.
    • The parser reads the Postman environment JSON, filters enabled variables, sanitizes their keys using sanitize_variables to match variables in imported collections, and writes them into a standard .env file.
  2. CLI Enhancements:
    • Updated the click options and execution logic in src/posting/__main__.py to support --type postman-env (or -t postman-env).
  3. Test Suite:
    • Added new unit test test_import_postman_env to tests/test_postman_import.py to assert environment conversion accuracy.
  4. Changelog:
    • Updated docs/CHANGELOG.md under the ## Unreleased section.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant