操作命令
curl -H "Accept-Encoding: gzip,deflate,sdch" -H "Accept-Language: en-US,en;q=0.8,zh-CN;q=0.6,zh;q=0.4" -H "User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2125.111 Safari/537.36" -H "Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8" -H "Cache-Control: max-age=0" -H "Connection: keep-alive" --compressed "https://finance.pae.baidu.com/selfselect/getstockquotation?code=300130&all=1&ktype=1&isIndex=false&isBk=false&isBlock=false&stockType=ab&eprop=yearK&group=quotation_kline_ab&finClientType=pc" | jq . > 300130.json
命令解释
-H "Accept-Encoding: gzip,deflate,sdch"
-H "Accept-Language: en-US,en;q=0.8,zh-CN;q=0.6,zh;q=0.4"
-H "User-Agent: Mozilla/5.0 (Windows NT 6.3; WOW64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/38.0.2125.111 Safari/537.36"
-H "Accept: text/html,application/xhtml+xml,application/xml;q=0.9,image/webp,*/*;q=0.8"
-H "Cache-Control: max-age=0" -H "Connection: kee