Skip to content

Import from curl & Postman

Three import paths, all producing ordinary Tinspec requests that you can then save, edit, and chain.

The fastest on-ramp. Copy a curl command from a terminal, from your browser’s network panel (“Copy as cURL”), or from a colleague’s message.

On an empty pane: with a project open and no tab, just press ⌘V. If the clipboard starts with curl, Tinspec parses it and opens each command as an unsaved request tab. Nothing touches disk until you save.

It handles the flags that matter: method, headers, data bodies, form fields (-F), and --data-binary '@path' for a file body.

Copying back out is equally faithful — Copy as cURL from the navigator or the Docs view emits -F and --data-binary '@path' for multipart and file bodies rather than silently dropping them.

Import a HAR capture to turn recorded traffic into requests. Useful when the API has no spec and you would otherwise be reading a network panel by hand.

Import a Postman collection. The mapping is deliberate about what it can and cannot carry:

PostmanBecomes
FoldersA name prefix on each request
{{var}}Kept verbatim — Postman and Tinspec use the same placeholder syntax
:id path paramsRewritten to {{id}}
Structured queryThe request’s first-class query map
raw / urlencoded / formdata / file / graphql bodiesThe matching Tinspec body
Bearer / Basic / API-key authMaterialised as headers or query parameters
Collection-level authInherited by each request
Scripts (pre-request, test)Not imported — reported as a per-request note
Unsupported auth typesNot imported — reported as a per-request note

Nothing is silently dropped: anything that could not be carried across comes back as a skipped note on the request it belonged to, so you can see what needs doing by hand.

Tinspec’s format has no inline-credential auth — a request references an auth provider by name, and credentials live in the keychain. So a Postman request carrying a bearer token becomes a request with that token as a literal header.

Treat imported credentials as a starting point, not a destination:

  1. Import.
  2. Create an auth provider for the real login flow.
  3. Point the requests at the provider and delete the literal header.

Otherwise you have moved a pasted token from one tool to another — and this one is going into git.

All three live in the Import stage of the add-source dialog. curl also has the ⌘V shortcut above and a Paste a curl command action on the welcome pane.

Insomnia, Bruno, and OpenAPI-as-import (a spec is bound, not imported) are not import sources at v0.1.0-preview.9.