Skip to content

Instantly share code, notes, and snippets.

@Htbaa
Last active December 16, 2015 05:19

Revisions

  1. Htbaa renamed this gist Apr 14, 2013. 1 changed file with 0 additions and 0 deletions.
    File renamed without changes.
  2. Htbaa created this gist Apr 14, 2013.
    18 changes: 18 additions & 0 deletions gistfile1.txt
    Original file line number Diff line number Diff line change
    @@ -0,0 +1,18 @@
    package main

    import (
    "fmt"
    "net/http"
    "io/ioutil"
    )

    func main() {
    resp, err := http.Get("http://maximus.htbaa.com/module/sources/json")
    if err != nil {
    fmt.Printf("Error: %s", err)
    return
    }
    defer resp.Body.Close()
    body, err := ioutil.ReadAll(resp.Body)
    fmt.Println(body)
    }