simplepaste.go
func (api * API) GetPasteTextById(paste_id string) (string, error) {
	response, err := http.Get("http://pastebin.com/raw.php?i=" + paste_id)
	defer response.Body.Close()
	if err != nil {
		return "", err
	}
	if response.StatusCode != 200 {
		return "", PasteGetError
	}
	buf := bytes.Buffer{}
	_, err = buf.ReadFrom(response.Body)
	if err != nil {
		return "", err
	}
	return buf.String(), nil
}
func (api * API) GetPasteTextById(paste_id string) (string, error) {
	response, err := http.Get("http://pastebin.com/raw.php?i=" + paste_id)
	defer response.Body.Close()
	if err != nil {
		return "", err
	}
	if response.StatusCode != 200 {
		return "", PasteGetError
	}
	buf := bytes.Buffer{}
	_, err = buf.ReadFrom(response.Body)
	if err != nil {
		return "", err
	}
	return buf.String(), nil
}
func ( api * API ) GetPasteTextById ( paste_id string ) ( string , error ) { response , err := http . Get ( " " + paste_id ) defer response . Body . Close ( ) if err != nil { return " " , err } if response . StatusCode != 200 { return " " , PasteGetError } buf := bytes . Buffer { } _ , err = buf . ReadFrom ( response . Body ) if err != nil { return " " , err } return buf . String ( ) , nil }
//Returns raw paste text
Returns raw paste text