Spaces:
Sleeping
Sleeping
Download test-hf.go from codebydante/BrodyFileStreamBot: direct link, hf CLI and curl.
- Browser
- Download file 426 Bytes
-
https://huggingface.co/spaces/codebydante/BrodyFileStreamBot/resolve/main/test-hf.go
- Command line
-
hf download hf://spaces/codebydante/BrodyFileStreamBot/test-hf.go
-
curl -L -o test-hf.go https://huggingface.co/spaces/codebydante/BrodyFileStreamBot/resolve/main/test-hf.go
426 Bytes
| package main | |
| import ( | |
| "fmt" | |
| "net/http" | |
| "io" | |
| "time" | |
| ) | |
| func main() { | |
| client := http.Client{Timeout: 30 * time.Second} | |
| resp, err := client.Get("https://codebydante-brodyfilestreambot.hf.space/") | |
| if err != nil { | |
| fmt.Println("Error fetching URL:", err) | |
| return | |
| } | |
| defer resp.Body.Close() | |
| body, _ := io.ReadAll(resp.Body) | |
| fmt.Println("Status:", resp.Status) | |
| fmt.Println("Body:", string(body)) | |
| } | |