Friday, March 11, 2016

Curl tips

Get response headers sending headers and cookies

curl --header "BB-App:androidNativeStore, 1.0.1" --cookie "lc=US|en" -I http://bitwise-api2.dev:8080/store-api/preferences/store-flag?store=us

HTTP/1.1 302 Found
Server: Apache-Coyote/1.1
X-Content-Type-Options: nosniff
X-XSS-Protection: 1; mode=block
Cache-Control: no-cache, no-store, max-age=0, must-revalidate
Pragma: no-cache
Expires: 0
X-Frame-Options: DENY
BB-Host: bitwise-api2.dev
Location: https://store.bbcomcdn.com/deploy/images/common/flags/flag_us.jpg
Content-Length: 0
Date: Fri, 11 Mar 2016 16:41:41 GMT