You are an expert in writing code in many different languages. Your goal is to perform code completion for the following code, keeping in mind the rest of the code and the file meta data.
    Metadata details:
    filename: teams.go
    path of file: ./repos/postgres-operator/pkg/util/teams
    
    the code of the file until where you have to start completion: package teams

import (
	"encoding/json"
	"fmt"
	"net/http"
	"strings"

	"github.com/sirupsen/logrus"
)

// InfrastructureAccount defines an account of the team on some infrastructure (i.e AWS, Google) platform.
type infrastructureAccount struct {
	ID          string `json:"id"`
	Name        string `json:"name"`
	Provider    string `json:"provider"`
	Type        string `json:"type"`
	Description string `json:"description"`
	Owner       string `json:"owner"`
	OwnerDn     string `json:"owner_dn"`
	Disabled    bool   `json:"disabled"`
}

// Team defines informaiton for a single team, including the list of members and i
    
func (t *API) TeamInfo(teamID, token string) (tm *Team, statusCode int, err error) {
	var (
		req  *http.Request
		resp *http.Response
	)

	url := fmt.Sprintf("%s/teams/%s", t.url, teamID)
	t.logger.Debugf("request url: %s", url)
	req, err = http.NewRequest("GET", url, nil)
	if err != nil {
		return nil, http.StatusBadRequest, err
	}

	req.Header.Add("Authorization", "Bearer "+token)
	if resp, err = t.httpClient.Do(req); err != nil {
		return nil, http.StatusUnauthorized, err
	}
	defer func() {
		if closeErr := resp.Body.Close(); closeErr != nil {
			err = fmt.Errorf("error when closing response: %v", closeErr)
		}
	}()
	statusCode = resp.StatusCode
	if statusCode != http.StatusOK {
		var raw map[string]json.RawMessage
		d := json.NewDecoder(resp.Body)
		err = d.Decode(&raw)
		if err != nil {
			return nil, statusCode, fmt.Errorf("team API query failed with status code %d and malformed response: %v", statusCode, err)
		}

		if errMessage, ok := raw["error"]; ok {
			return nil, statusCode, fmt.Errorf("team API query failed with status code %d and message: '%v'", statusCode, string(errMessage))
		}
		return nil, statusCode, fmt.Errorf("team API query failed with status code %d", statusCode)
	}

	tm = &Team{}
	d := json.NewDecoder(resp.Body)
	if err = d.Decode(tm); err != nil {
		return nil, statusCode, fmt.Errorf("could not parse team API response: %v", err)
	}

	return tm, statusCode, nil
}