Skip to content

Instantly share code, notes, and snippets.

@entyo
Created March 12, 2017 04:11
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save entyo/f0d9bab9ef2577e2f3b19bddbfd5aa14 to your computer and use it in GitHub Desktop.
Save entyo/f0d9bab9ef2577e2f3b19bddbfd5aa14 to your computer and use it in GitHub Desktop.
http.Responseのbodyを見たいとき
// bodyの確認
body, err := ioutil.ReadAll(resp.Body)
if err != nil {
log.Fatalln(err)
}
fmt.Printf("body: " + string(body) + "\n")
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment