Skip to content

Latest commit

 

History

History
36 lines (26 loc) · 542 Bytes

README.md

File metadata and controls

36 lines (26 loc) · 542 Bytes

Cloudflare Challenge Solver

A port of cloudflare-scrape.

Usage

package main

import (
    "github.com/cardigann/go-cloudflare-scraper"
)


func main() {
	scraper, err := scraper.NewTransport(http.DefaultTransport)
	if err != nil {
		log.Fatal(err)
	}

	c := http.Client{Transport: scraper}

	res, err := c.Get(ts.URL)
	if err != nil {
		log.Fatal(err)
	}

	body, err = ioutil.ReadAll(res.Body)
	res.Body.Close()
	if err != nil {
		log.Fatal(err)
	}
}