INNER CODE UNIT · Go

client

LerianStudio/midaz · scripts/analyze_accepted/main.go:59

	client := &http.Client{Timeout: 5 * time.Second}

	resp, err := client.Do(req)
	if err != nil {
		return 0, err
	}
	defer resp.Body.Close()

	if resp.StatusCode != http.StatusOK {
		_, _ = io.ReadAll(resp.Body)

		return 0, fmt.Errorf("status %d", resp.StatusCode)
	}

	var body struct {
		Items []struct {
			AssetCode string `json:"assetCode"`
			Available any    `json:"available"`

View source record →

📰 Research Paper
Loading…
⏳ Fetching content…