Documentation
¶
Overview ¶
Package gcp provides authenticated HTTP access to GCP APIs using Application Default Credentials. It is a shared foundation used by the Vertex AI inference provider and the GCF dispatch provisioner.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ExtractErrorMessage ¶
ExtractErrorMessage parses a GCP API error response and returns only the error message, avoiding leakage of sensitive metadata.
Types ¶
type Client ¶
type Client struct {
QuotaProject string
// contains filtered or unexported fields
}
Client provides authenticated HTTP access to GCP APIs using Application Default Credentials.
func NewClientWithHTTP ¶
NewClientWithHTTP creates a Client that uses the given HTTP client and a static "test-token" for auth. Intended for unit tests that redirect GCP API calls to httptest servers.
func (*Client) AccessToken ¶
AccessToken obtains a GCP access token using Application Default Credentials.