I'm trying to make a simple http request to https://ip2country.info/ using httpie.
For the life of me I can't get it to work. I'm trying to request to this URL: https://api.ip2country.info/ip?5.6.7.8
When I use this in Postman it works perfectly. But in httpie here's my request and response:
Request: http api.ip2country.info ip==5.6.7.8
Response: HTTP/1.1 301 Moved Permanently
Any help would be appreciated!
Edit: Screenshots


Test Case
The request, as stands, to
https://api.ip2country.info/ip?5.6.7.8by httpie return a redirect error code, yet works in postmanapi.ip2country.info/ip?5.6.7.8.Solution
The request works in postman because postman directly accesses the url with hard-coded query params. Httpie is supposed to be "easier" by allowing a builder interfact on the command line.
The command
http api.ip2country.info ip==5.6.7.8will essentially build a request tohttp://api.ip2country.info?ip=5.6.7.8which is different then the intended url plugged into postman.https://api.ip2country.info/ip?5.6.7.8http://api.ip2country.info?ip=5.6.7.8By directly coding the query params into httpie and changing the scheme to https like
https api.ip2country.info/ip?5.6.7.1, a response ofis retrieved. The only provided query param is a single key IP with no value, which httpie doesn't support in their builder (since it's fairly taboo), and requires it to just be manually appended to the end of the request URL with
?{ip}