[GH-ISSUE #5013] [bug]: Import cURL parameter Incorrect #1907

Closed
opened 2026-03-16 22:20:19 +03:00 by kerem · 3 comments
Owner

Originally created by @farrywen on GitHub (Apr 22, 2025).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/5013

Originally assigned to: @shuaixr on GitHub.

Is there an existing issue for this?

  • I have searched existing issues and this bug hasn't been reported yet

Current behavior

When I import a request via cURL, the parameter names and values ​​are messed up and cannot be matched.

Steps to reproduce

I imported cURL as follows:

curl --request POST \ --url https://api.stripe.com/v1/accounts/acct_1RAlgzRwv8GWMpvL \ --header 'Accept: */*' \ --header 'Accept-Encoding: gzip, deflate, br' \ --header 'Authorization: Basic c2tfdGVzdF81MVBKakxMUnVuVUV0Q1lHWHFmYWJpYU9ielAzYUJvSUJvU0hVeGtFUWlQWTZjcnBKVm5vVktKOUh0cVBONzBpYVN6QUZkeUVtM2tRZDV0dFNYWXpTcEY1aDAwczlXWW85Q1g6' \ --header 'Connection: keep-alive' \ --header 'User-Agent: PostmanRuntime-ApipostRuntime/1.1.0' \ --data 'individual[first_name]=John' \ --data 'individual[last_name]=Doe' \ --data 'individual[email]=ray.arrakis@gmail.com' \ --data 'individual[phone]= +639615051036' \ --data 'individual[dob][day]=15' \ --data 'individual[dob][month]=6' \ --data 'individual[dob][year]=1990' \ --data 'individual[address][line1]=123 Main Street' \ --data 'individual[address][city]=London' \ --data 'individual[address][state]=London' \ --data 'individual[address][postal_code]=EC1Y8SY' \ --data 'individual[address][country]=GB' \ --data business_type=individual \ --data 'business_profile[product_description]=Ticket resale' \ --data 'business_profile[mcc]=7922' \ --data 'tos_acceptance[date]=1743825911' \ --data 'tos_acceptance[ip]=154.64.226.44'

The parameters after import are as follows :

Image

The parameter names and values ​​are all messed up.

Logs and Screenshots


Environment

Production

Hoppscotch Version

Local

Interceptor

Not Applicable - Issue not related to network requests

Browsers Affected

No response

Operating System

Windows

Additional Information

No response

Originally created by @farrywen on GitHub (Apr 22, 2025). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/5013 Originally assigned to: @shuaixr on GitHub. ### Is there an existing issue for this? - [x] I have searched existing issues and this bug hasn't been reported yet ### Current behavior When I import a request via cURL, the parameter names and values ​​are messed up and cannot be matched. ### Steps to reproduce I imported cURL as follows: `curl --request POST \ --url https://api.stripe.com/v1/accounts/acct_1RAlgzRwv8GWMpvL \ --header 'Accept: */*' \ --header 'Accept-Encoding: gzip, deflate, br' \ --header 'Authorization: Basic c2tfdGVzdF81MVBKakxMUnVuVUV0Q1lHWHFmYWJpYU9ielAzYUJvSUJvU0hVeGtFUWlQWTZjcnBKVm5vVktKOUh0cVBONzBpYVN6QUZkeUVtM2tRZDV0dFNYWXpTcEY1aDAwczlXWW85Q1g6' \ --header 'Connection: keep-alive' \ --header 'User-Agent: PostmanRuntime-ApipostRuntime/1.1.0' \ --data 'individual[first_name]=John' \ --data 'individual[last_name]=Doe' \ --data 'individual[email]=ray.arrakis@gmail.com' \ --data 'individual[phone]= +639615051036' \ --data 'individual[dob][day]=15' \ --data 'individual[dob][month]=6' \ --data 'individual[dob][year]=1990' \ --data 'individual[address][line1]=123 Main Street' \ --data 'individual[address][city]=London' \ --data 'individual[address][state]=London' \ --data 'individual[address][postal_code]=EC1Y8SY' \ --data 'individual[address][country]=GB' \ --data business_type=individual \ --data 'business_profile[product_description]=Ticket resale' \ --data 'business_profile[mcc]=7922' \ --data 'tos_acceptance[date]=1743825911' \ --data 'tos_acceptance[ip]=154.64.226.44'` The parameters after import are as follows : ![Image](https://github.com/user-attachments/assets/7953921b-4469-444e-ba52-7eb73cefbda7) The parameter names and values ​​are all messed up. ### Logs and Screenshots ```shell ``` ### Environment Production ### Hoppscotch Version Local ### Interceptor Not Applicable - Issue not related to network requests ### Browsers Affected _No response_ ### Operating System Windows ### Additional Information _No response_
kerem 2026-03-16 22:20:19 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@shuaixr commented on GitHub (May 2, 2025):

@jamesgeorge007 I would like to work on this
Add -H "Content-Type: application/x-www-form-urlencoded" to the curl command can fix this error.
According to the curl documentation, when using the -d option for POST requests, curl automatically includes the Content-Type: application/x-www-form-urlencoded header.
Hoppscotch doesn't account for this, which I believe is a bug.

<!-- gh-comment-id:2846698591 --> @shuaixr commented on GitHub (May 2, 2025): @jamesgeorge007 I would like to work on this Add -H "Content-Type: application/x-www-form-urlencoded" to the curl command can fix this error. According to the [curl documentation](https://everything.curl.dev/http/post/content-type.html), when using the -d option for POST requests, curl automatically includes the Content-Type: application/x-www-form-urlencoded header. Hoppscotch doesn't account for this, which I believe is a bug.
Author
Owner

@jamesgeorge007 commented on GitHub (May 2, 2025):

Feel free to raise a PR :)

<!-- gh-comment-id:2846849070 --> @jamesgeorge007 commented on GitHub (May 2, 2025): Feel free to raise a PR :)
Author
Owner

@jamesgeorge007 commented on GitHub (May 8, 2025):

This is resolved in the latest release. Please feel free to let us know if you have any feedback.

<!-- gh-comment-id:2862651232 --> @jamesgeorge007 commented on GitHub (May 8, 2025): This is resolved in the latest release. Please feel free to let us know if you have any feedback.
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/hoppscotch#1907
No description provided.