@fogine thanks for the feedback! It's really valuable. I agree with you that current business model probably won't work and it retrains the community from growing. So I think I'll change my direction here. Instead of monetizing the core product (http-prompt), we should make another related product based on http-prompt. The related product is probably an SaaS that bring more organization-specific features to http-prompt, similar to what Postman and Insomnia do. Anyway, it's still undecided. In the short term, I would do the following:
Let me know if you have any other ideas. Thanks!
Hello all. Just found about this command line client. Is there a way to store/list/add/remove/manage a list of presets? Similar somehow to what you can do in Postman. What I mean is something like editing an input file in some format where you can list all your preset REST calls with their own properties. E.g.:
presets: [{
name: 'Load foos - Local machine',
url: 'http://localhost:1234/api/foo',
verb: 'get',
authorization: {
type: 'basic',
username: 'johndoe',
password: 'SECRET PASSWORD',
},
headers: [{
key: 'accept',
value: 'application/json',
}],
}, {
...
}],
and then be able to feed one of this presets into http prompt command line: http-prompt --input ./my-presets.conf --preset 'Load foos - Local machine'
env
command does. You can export the env
output to a file. Then import it with exec
or source
command. Refer to the doc here: http://docs.http-prompt.com/en/latest/user-guide.html#saving-and-loading-sessions
file.json content
{
"addr0": "Unit 315, 3/f PAK TIN ESTATE, BLOCK 10, Shek Kip Mei",
"reference": "1",
"returnRecords": 10
}
when I run with debug mode , the content is
"data": "{\"field\": \"{\r\n\t\\"addr0\\": \\"Unit 315, 3/f PAK TIN ESTATE, BLOCK 10, Shek Kip Mei\\",\r\n\t\\"reference\\": \\"1\\",\r\n\t\\"returnRecords\\": 10\r\n}\"}",
it seems that , http-prompt add redundant file in the json content "file: {}" . I really dont need it.
source .bash_profile
Hello everyone. It seems for me, that http-prompt somehow ignores Content-Type: application/x-www-form-urlencoded
. Even though httpie
preview returns the right command
http --form --proxy=https://localhost:9999 --verbose --verify=no http://example.com password=bar username=foo Content-Type:application/x-www-form-urlencoded
the actual request treats the body to be json
http://example.com> post
POST / HTTP/1.1
Accept: application/json, */*
Accept-Encoding: gzip, deflate
Connection: keep-alive
Content-Length: 38
Content-Type: application/x-www-form-urlencoded
Host: example.com
User-Agent: HTTPie/2.0.0
{"password": "bar", "username": "foo"}
Whereas, when running the httpie
command directly on the shell, it's interpreted correctly
$ http --form --proxy=https://localhost:9999 --verbose --verify=no http://example.com password=bar username=foo Content-Type:application/x-www-form-urlencoded
POST / HTTP/1.1
Accept: */*
Accept-Encoding: gzip, deflate
Connection: keep-alive
Content-Length: 25
Content-Type: application/x-www-form-urlencoded
Host: example.com
User-Agent: HTTPie/2.0.0
password=bar&username=foo
Has someone experienced this issue so far as well? Was browsing the reported issue, but couldn't find something related.
Hello !
Trying to send a GET request with digest auth, I get the following error :
❯ http-prompt http://app.example.com:8080
Version: 1.0.0
http://app.example.com:8080> --auth-type digest
http://app.example.com:8080> --auth foo:bar
http://app.example.com:8080> get
usage: http [--json] [--form] [--compress] [--pretty {all,colors,format,none}] [--style STYLE] [--unsorted] [--sorted] [--format-options FORMAT_OPTIONS] [--print WHAT] [--headers] [--body] [--verbose]
[--all] [--history-print WHAT] [--stream] [--output FILE] [--download] [--continue] [--session SESSION_NAME_OR_PATH | --session-read-only SESSION_NAME_OR_PATH] [--auth USER[:PASS]]
[--auth-type {basic,digest}] [--ignore-netrc] [--offline] [--proxy PROTOCOL:PROXY_URL] [--follow] [--max-redirects MAX_REDIRECTS] [--max-headers MAX_HEADERS] [--timeout SECONDS] [--check-status]
[--path-as-is] [--verify VERIFY] [--ssl {ssl2.3,tls1,tls1.1,tls1.2}] [--ciphers CIPHERS] [--cert CERT] [--cert-key CERT_KEY] [--ignore-stdin] [--help] [--version] [--traceback]
[--default-scheme DEFAULT_SCHEME] [--debug]
[METHOD] URL [REQUEST_ITEM [REQUEST_ITEM ...]]
http: error: unrecognized arguments: GET http://app.example.com:8080
Any tip is welcome. Thx !