[GH-ISSUE #3109] Import CURL does not work #1023

Closed
opened 2026-03-16 18:06:36 +03:00 by kerem · 5 comments
Owner

Originally created by @oridamari on GitHub (Jun 4, 2023).
Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/3109

Hey,

Trying to import a valid CURL and it does not work, it only sets the method type, and sometimes sets the headers and body,
and the URL is set to https://echo.hoppscotch.io/

curl --location 'http://my-private-url.test.com'
--header 'Accept: application/jsonx'
--header 'Content-Type: application/jsonx'
--data '{"a":1,"b":2,"c":3}'

the curl imports fine in Postman.

Can you please check and advise? thanks

Originally created by @oridamari on GitHub (Jun 4, 2023). Original GitHub issue: https://github.com/hoppscotch/hoppscotch/issues/3109 Hey, Trying to import a valid CURL and it does not work, it only sets the method type, and sometimes sets the headers and body, and the URL is set to https://echo.hoppscotch.io/ curl --location 'http://my-private-url.test.com' \ --header 'Accept: application/jsonx' \ --header 'Content-Type: application/jsonx' \ --data '{"a":1,"b":2,"c":3}' the curl imports fine in Postman. Can you please check and advise? thanks
kerem 2026-03-16 18:06:36 +03:00
  • closed this issue
  • added the
    bug
    label
Author
Owner

@pratyush-pankaj commented on GitHub (Jun 6, 2023):

Same issue with me. Please someone fix this

<!-- gh-comment-id:1579496159 --> @pratyush-pankaj commented on GitHub (Jun 6, 2023): Same issue with me. Please someone fix this
Author
Owner

@bermudi commented on GitHub (Jun 7, 2023):

Possibly related https://github.com/hoppscotch/hoppscotch/issues/1159

<!-- gh-comment-id:1579772503 --> @bermudi commented on GitHub (Jun 7, 2023): Possibly related https://github.com/hoppscotch/hoppscotch/issues/1159
Author
Owner

@micky2333 commented on GitHub (Jun 27, 2023):

Yes, I have the same problem Import CURL can't import request header and request body
Please someone fix this
This function is very important

curl 'https://blog.52ipc.top/joe/api' \ -H 'Connection: keep-alive' \ -H 'User-Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 15_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.0 Mobile/15E148 Safari/604.1 wechatdevtools/1.06.2306020 MicroMessenger/8.0.5 webview/' \ -H 'token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1N' \ -H 'content-type: application/json' \ -H 'Accept: */*' \ -H 'Sec-Fetch-Site: cross-site' \ -H 'Sec-Fetch-Mode: cors' \ -H 'Sec-Fetch-Dest: empty' \ -H 'Referer: https://servicewechat.com/wx7e2a0ea0a73932f3/devtools/page-frame.html' \ --data-binary '{"pageNum":1,"pageSize":100,"cityId":"110100","categoryId":"","isFirstPage":"1"}' \ --compressed

<!-- gh-comment-id:1608743525 --> @micky2333 commented on GitHub (Jun 27, 2023): Yes, I have the same problem Import CURL can't import request header and request body Please someone fix this This function is very important ` curl 'https://blog.52ipc.top/joe/api' \ -H 'Connection: keep-alive' \ -H 'User-Agent: Mozilla/5.0 (iPhone; CPU iPhone OS 15_0 like Mac OS X) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/15.0 Mobile/15E148 Safari/604.1 wechatdevtools/1.06.2306020 MicroMessenger/8.0.5 webview/' \ -H 'token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1N' \ -H 'content-type: application/json' \ -H 'Accept: */*' \ -H 'Sec-Fetch-Site: cross-site' \ -H 'Sec-Fetch-Mode: cors' \ -H 'Sec-Fetch-Dest: empty' \ -H 'Referer: https://servicewechat.com/wx7e2a0ea0a73932f3/devtools/page-frame.html' \ --data-binary '{"pageNum":1,"pageSize":100,"cityId":"110100","categoryId":"","isFirstPage":"1"}' \ --compressed `
Author
Owner

@liyasthomas commented on GitHub (Jun 27, 2023):

Resolved in #3152.

<!-- gh-comment-id:1609444526 --> @liyasthomas commented on GitHub (Jun 27, 2023): Resolved in #3152.
Author
Owner

@chaoqunya commented on GitHub (Jun 30, 2023):

Still cannot import curl command like this one

curl -s --user 'api:YOUR_API_KEY' -G \
      https://api.mailgun.net/v3/YOUR_DOMAIN_NAME/events \
      --data-urlencode begin='Fri, 3 May 2013 09:00:00 -0000' \
      --data-urlencode ascending=yes \
      --data-urlencode limit=25 \
      --data-urlencode pretty=yes \
      --data-urlencode recipient=joe@example.com
<!-- gh-comment-id:1614171066 --> @chaoqunya commented on GitHub (Jun 30, 2023): Still cannot import curl command like this one ```shell curl -s --user 'api:YOUR_API_KEY' -G \ https://api.mailgun.net/v3/YOUR_DOMAIN_NAME/events \ --data-urlencode begin='Fri, 3 May 2013 09:00:00 -0000' \ --data-urlencode ascending=yes \ --data-urlencode limit=25 \ --data-urlencode pretty=yes \ --data-urlencode recipient=joe@example.com ```
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#1023
No description provided.