hitspec can import Postman collections and convert them to .http files. This guide covers the import process and key differences.
Importing a Collection
Export your Postman collection as JSON (Collection v2.1), then import:
This converts all requests in the collection, including folders, headers, and bodies.
What Gets Converted
hitspec also imports from:
OpenAPI / Swagger
curl Commands
Insomnia
Key Differences from Postman
Test Syntax
Postman (JavaScript)
hitspec (declarative)
Variables
Authentication
Request Dependencies
After Import
After importing, you should:
- Add assertions — the import generates basic
expect status == 200 assertions. Add more specific ones.
- Replace hardcoded values — use variables and
{{$env()}} for URLs, tokens, etc.
- Add captures — chain requests with
>>>capture blocks and @depends.
- Set up environments — create
hitspec.yaml with your environments.
Exporting Back to curl
You can also export hitspec files to curl for debugging:
Last modified on July 13, 2026