micha / resty

Little command line REST client that you can use in pipelines (bash or zsh).
MIT License
2.65k stars 143 forks source link

Setting default query string for every request #44

Open jayyvis opened 10 years ago

jayyvis commented 10 years ago

I am trying to set default query string to be passed for every request but it's not picking up

resty https://api.hipchat.com/v2 -H "Content-Type: application/json" -q "auth_token=ASD"
AdrieanKhisbe commented 7 years ago

@jayyvis I retest your query with the new dry run feature and it seams to be working normaly:

> resty https://api.hipchat.com/v2 -H "Content-Type: application/json" -q "auth_token=ASD"
https://api.hipchat.com/v2*

> GET / --dry-run
curl -sLv '' -X GET -b "/Users/abecchis/.resty/c/api.hipchat.com" -c "/Users/abecchis/.resty/c/api.hipchat.com" -H Content-Type:\ application/json -q auth_token=ASD "https://api.hipchat.com/v2/"

> POST / --dry-run
curl -sLv '' -X POST -b "/Users/abecchis/.resty/c/api.hipchat.com" -c "/Users/abecchis/.resty/c/api.hipchat.com" -H Content-Type:\ application/json -q auth_token=ASD "https://api.hipchat.com/v2/"

Have you tried with latest version?

(sorry for the late answer ::/)