postman-app-support icon indicating copy to clipboard operation
postman-app-support copied to clipboard

Using curl to export and re-import breaks the POST data encoding

Open scor opened this issue 8 months ago • 0 comments
trafficstars

Is there an existing issue for this?

  • [x] I have searched the tracker for existing similar issues and I know that duplicates will be closed

Describe the Issue

I sometimes use the curl code snippet in the right sidebar to move request from one workspace to another. This time, I could not figure out why my request was failing after importing. In the end, I found a special character that didn't make it through

Steps To Reproduce

  1. start with a POST request containing a param like mp+8/ay70X(first screenshot)
  2. copy the curl output: curl --location 'https://example.org/' \ --header 'Content-Type: application/x-www-form-urlencoded' \ --data-urlencode 'param=mp+8/ay70X'
  3. open new Postman window click "Import"
  4. paste the curl command
  5. observe that the request was imported with the wrong parameter value: mp 8/ay70X

Screenshots or Videos

Export this request Image After import

Image

Operating System

macOS

Postman Version

11.34.3

Postman Platform

Postman App

User Account Type

Signed In User

Additional Context?

No response

scor avatar Mar 04 '25 19:03 scor