You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The Code->cURL generator and Postman import is useful for us to share post-body requests around without having to save it to a collection. The cURL generation is either not imported correctly (with new Code Generation) or is imported but not separated into key/value pairs under x-www-form-urlencoded.
For our workflow, saving a collection is an issue because it inundates our space with just "example" requests and even more severe is that it can be accidentally and unexpectedly mutated (more sensitive if after sharing).
To Reproduce
Steps to reproduce the behavior:
Use "New Code Generation Mode"
Import this request:
curl --location --request POST 'https://httpbin.org/post'
--header 'accept: application/json'
--header 'Content-Type: application/x-www-form-urlencoded'
-d 'test=test'
Click on 'Code'
Scroll down to 'cURL' and copy the content
Import the recently copied content
Body is empty (it is likely because postman import doesn't recognize --data-urlencode)
Note: If New Code Generation Mode is on, then the body does get populated but is not interpreted into the individual key/value pairs in body under x-www-form-urlencoded
Expected behavior
Post man should be able to import its exported cURL requests. Or the legacy behaviour should be imported with the original key/value pairs.
Screenshots
App information (please complete the following information):
Postman Version 7.21.1
OS: Catalina 10.15.4
Additional context
Ultimately, we are looking for an easy copy+paste solution for http-request sharing so that we can share without the need of saving and naming collections.
Previously we were able to flawless do this with the legacy code generation method because it would split each variable as a separate -d. Now it just congeals it all together under one -d and we have to manually perform an awkward search and replace to separate it again.
The new code generation probably would work very well if the import mechanic supported --data-urlencode
It is further awkward that the Postman cURL generation can't generate a request that can be perfectly imported by Postman.
The text was updated successfully, but these errors were encountered:
The Code->cURL generator and Postman import is useful for us to share post-body requests around without having to save it to a collection. The cURL generation is either not imported correctly (with new Code Generation) or is imported but not separated into key/value pairs under x-www-form-urlencoded.
For our workflow, saving a collection is an issue because it inundates our space with just "example" requests and even more severe is that it can be accidentally and unexpectedly mutated (more sensitive if after sharing).
To Reproduce
Steps to reproduce the behavior:
curl --location --request POST 'https://httpbin.org/post'
--header 'accept: application/json'
--header 'Content-Type: application/x-www-form-urlencoded'
-d 'test=test'
Note: If New Code Generation Mode is on, then the body does get populated but is not interpreted into the individual key/value pairs in body under x-www-form-urlencoded
Expected behavior
Post man should be able to import its exported cURL requests. Or the legacy behaviour should be imported with the original key/value pairs.
Screenshots
![image](https://user-images.githubusercontent.com/17076/78719703-ffa5f200-78e9-11ea-98a9-f02f83415181.png)
![image](https://user-images.githubusercontent.com/17076/78719754-151b1c00-78ea-11ea-9a20-841c2ea066db.png)
![image](https://user-images.githubusercontent.com/17076/78719814-2d8b3680-78ea-11ea-879a-e8f1e12b7a76.png)
![image](https://user-images.githubusercontent.com/17076/78719855-3e3bac80-78ea-11ea-9f0f-b810e8763675.png)
App information (please complete the following information):
Additional context
Ultimately, we are looking for an easy copy+paste solution for http-request sharing so that we can share without the need of saving and naming collections.
Previously we were able to flawless do this with the legacy code generation method because it would split each variable as a separate
-d
. Now it just congeals it all together under one-d
and we have to manually perform an awkward search and replace to separate it again.The new code generation probably would work very well if the import mechanic supported
--data-urlencode
It is further awkward that the Postman cURL generation can't generate a request that can be perfectly imported by Postman.
The text was updated successfully, but these errors were encountered: