func (c Client) ConfiguredTargets(targetName, configID string) ConfiguredTargets {
	return ConfiguredTargets{
		Client: c,
		target: targetName,
		config: configID,
	}
}
ConfiguredTargets provides CRUD methods for a target's configured targets.
package resultstore
import (
	"context"
	"crypto/x509"
	"fmt"
	"strings"
	"github.com/google/uuid"
	resultstore "google.golang.org/genproto/googleapis/devtools/resultstore/v2"
	"google.golang.org/genproto/protobuf/field_mask"
	"google.golang.org/grpc"
	"google.golang.org/grpc/credentials"
	"google.golang.org/grpc/credentials/oauth"
	"google.golang.org/grpc/metadata"
)
func Connect(ctx context.Context, serviceAccountPath string) (*grpc.ClientConn, error) {
	pool, err := x509.SystemCertPool()
	if err != nil {
		return nil, fmt.Errorf("system cert pool: %v", err)
	}
	creds := credentials.NewClientTLSFromCert(pool, "")
	const scope = "https://www.googleapis.com/auth/cloud-platform"
	var perRPC credentials.PerRPCCredentials
	if serviceAccountPath != "" {
		perRPC, err = oauth.NewServiceAccountFromFile(serviceAccountPath, scope)
	} else {
		perRPC, err = oauth.NewApplicationDefault(ctx, scope)
	}
	if err != nil {
		return nil, fmt.Errorf("create oauth: %v", err)
	}
	conn, err := grpc.Dial(
		"resultstore.googleapis.com:443",
		grpc.WithTransportCredentials(creds),
		grpc.WithPerRPCCredentials(perRPC),
	)
	if err != nil {
		return nil, fmt.Errorf("dial: %v", err)
	}
	return conn, nil
}
type Secret string
func UUID() string {
	return uuid.New().String()
}
func NewSecret() Secret {
	return Secret(UUID())
}
type Client struct {
	up    resultstore.ResultStoreUploadClient
	down  resultstore.ResultStoreDownloadClient
	ctx   context.Context
	token string
}
func NewClient(conn *grpc.ClientConn) *Client {
	return &Client{
		up:   resultstore.NewResultStoreUploadClient(conn),
		down: resultstore.NewResultStoreDownloadClient(conn),
		ctx:  context.Background(),
	}
}
func (c *Client) WithContext(ctx context.Context) *Client {
	c.ctx = ctx
	return c
}
func (c *Client) WithSecret(authorizationToken Secret) *Client {
	c.token = string(authorizationToken)
	return c
}
func (c Client) Invocations() Invocations {
	return Invocations{
		Client: c,
	}
}
func (c Client) Configurations(invocationName string) Configurations {
	return Configurations{
		Client: c,
		inv:    invocationName,
	}
}
func (c Client) Targets(invocationName string) Targets {
	return Targets{
		Client: c,
		inv:    invocationName,
	}
}