Versions in this module Expand all Collapse all v1 v1.1.3 Sep 8, 2026 Changes in this version + const DefaultMaxResponseBodyBytes + const EdgeSecretHeader + var ErrAPITokenRequired = errors.New("goldsky: REST project API token is required") type Client + func NewDataClient(options ...Option) (*Client, error) type Option + func WithMaxResponseBodyBytes(n int64) Option type UpdateEdgeEndpointRequest + ClearRateLimitBudget bool + func (r UpdateEdgeEndpointRequest) MarshalJSON() ([]byte, error) v1.1.2 Sep 8, 2026 Changes in this version + type Clock interface + Now func() time.Time type PipelineDefinition + Name string + type Sleeper interface + Sleep func(context.Context, time.Duration) error v1.0.0 Sep 8, 2026 Changes in this version + const DefaultBaseURL + const DefaultEdgeBaseURL + const DefaultGraphQLBaseURL + const DefaultUserAgent + const WebhookSecretHeader + func VerifyWebhookRequest(r *http.Request, expected string) bool + func VerifyWebhookSecret(provided, expected string) bool + type CatalogService struct + func (s *CatalogService) EdgeNetworks(ctx context.Context) (EdgeNetworksResponse, error) + func (s *CatalogService) EdgeSources(ctx context.Context) (EdgeSourcesResponse, error) + func (s *CatalogService) SupportedSubgraphChains(ctx context.Context) (SubgraphChainsResponse, error) + type Client struct + Catalogs *CatalogService + Edge *EdgeService + GraphQL *GraphQLService + Pipelines *PipelineService + RPC *RPCService + Subgraphs *SubgraphService + Webhooks *WebhookService + func NewClient(apiToken string, options ...Option) (*Client, error) + func (c *Client) BaseURL() string + func (c *Client) SetEdgeAPIKey(key string) + func (c *Client) UserAgent() string + type CreateEdgeEndpointRequest struct + AllowedDomains []string + Name string + Product *EdgeProduct + RateLimitBudget *EdgeRateLimitBudget + type CreateEdgeEndpointResponse struct + Data struct{ ... } + Warnings []string + type CreatePipelineRequest struct + Definition PipelineDefinition + Description string + Name string + ResourceSize string + UseDedicatedIP *bool + type CreateWebhookRequest struct + Entity string + Name string + NumRetries *int + RetryIntervalSeconds *int + RetryTimeoutSeconds *int + Secret *string + SubgraphName string + SubgraphVersion string + WebhookURL string + type CreateWebhookResponse struct + Data struct{ ... } + type DeploySubgraphOptions struct + Bundle io.Reader + BundleFilename string + Description string + GraftFrom string + GraphNodeShard string + Overwrite string + RemoveGraft string + SkipGraftValidation string + StartBlock string + type EdgeEndpoint struct + AllowedDomains []string + CreatedAt time.Time + Name string + PausedAt *time.Time + Product EdgeProduct + RateLimitBudget *string + Status EdgeStatus + UpdatedAt time.Time + type EdgeMetricsData struct + Errors []MetricPoint + Requests []MetricPoint + type EdgeMetricsOptions struct + BucketSize string + From time.Time + To time.Time + type EdgeMetricsResponse struct + Data EdgeMetricsData + type EdgeNetwork struct + ChainID *json.Number + ChainName string + LogoURL string + Name string + NetworkName string + type EdgeNetworksResponse struct + Data []EdgeNetwork + type EdgePager struct + func (p *EdgePager) NextPage(ctx context.Context) (Page[EdgeEndpoint], error) + type EdgeProduct string + const EdgeProductBoost + const EdgeProductData + const EdgeProductRPC + type EdgeRateLimitBudget string + const EdgeTier180k500PerIP + const EdgeTier180kUnlimitedPerIP + const EdgeTier360k500PerIP + const EdgeTier360kUnlimitedPerIP + const EdgeTier600k500PerIP + const EdgeTier600kUnlimitedPerIP + const EdgeTier60k500PerIP + const EdgeTier60kUnlimitedPerIP + const EdgeTier6k500PerIP + const EdgeTier6kUnlimitedPerIP + const EdgeTierUnlimited100PerIP + const EdgeTierUnlimited500PerIP + type EdgeService struct + func (s *EdgeService) Create(ctx context.Context, req CreateEdgeEndpointRequest) (CreateEdgeEndpointResponse, error) + func (s *EdgeService) Delete(ctx context.Context, name string) error + func (s *EdgeService) Get(ctx context.Context, name string) (EdgeEndpoint, error) + func (s *EdgeService) List(ctx context.Context, opts ListEdgeEndpointsOptions) (Page[EdgeEndpoint], error) + func (s *EdgeService) Metrics(ctx context.Context, name string, opts EdgeMetricsOptions) (EdgeMetricsResponse, error) + func (s *EdgeService) NewEdgePager(opts ListEdgeEndpointsOptions) *EdgePager + func (s *EdgeService) Pause(ctx context.Context, name string) (EdgeEndpoint, error) + func (s *EdgeService) Resume(ctx context.Context, name string) (EdgeEndpoint, error) + func (s *EdgeService) RevealKey(ctx context.Context, name string) (RevealEdgeKeyResponse, error) + func (s *EdgeService) Update(ctx context.Context, name string, req UpdateEdgeEndpointRequest) (EdgeEndpoint, error) + type EdgeSource struct + Description string + Endpoint string + ID string + LogoURL string + Name string + ProviderID string + ProviderName string + type EdgeSourcesResponse struct + Data []EdgeSource + type EdgeStatus string + const EdgeStatusActive + const EdgeStatusPaused + type GraphQLError struct + Message string + Raw json.RawMessage + func (e *GraphQLError) UnmarshalJSON(b []byte) error + type GraphQLRequest struct + OperationName string + Query string + Variables map[string]any + type GraphQLResponse struct + Data json.RawMessage + Errors []GraphQLError + Extensions json.RawMessage + Header http.Header + Status int + func (r *GraphQLResponse) HasErrors() bool + type GraphQLService struct + func (s *GraphQLService) PrivateURL(projectID, subgraphName, versionOrTag string) string + func (s *GraphQLService) PublicURL(projectID, subgraphName, versionOrTag string) string + func (s *GraphQLService) Query(ctx context.Context, endpoint string, req GraphQLRequest, auth bool) (GraphQLResponse, error) + func (s *GraphQLService) QueryPrivate(ctx context.Context, projectID, subgraphName, versionOrTag string, ...) (GraphQLResponse, error) + func (s *GraphQLService) QueryPublic(ctx context.Context, projectID, subgraphName, versionOrTag string, ...) (GraphQLResponse, error) + type IndexingProgress struct + ChainHeadBlock json.Number + DeploymentHeadBlock json.Number + DeploymentStartBlock json.Number + Network string + ProgressPercent json.Number + Synced bool + type ListEdgeEndpointsOptions struct + PageSize int + PageToken string + Product string + type ListPipelinesOptions struct + PageSize int + PageToken string + Type string + type ListSubgraphsOptions struct + PageSize int + PageToken string + type LogRecord struct + Level string + Text string + Timestamp json.Number + type LogResults struct + Cursor *json.Number + Results []LogRecord + type MetricPoint struct + Time string + Value json.Number + type Option func(*config) + func WithBaseURL(url string) Option + func WithClock(cl clock.Clock) Option + func WithEdgeAPIKey(key string) Option + func WithEdgeBaseURL(url string) Option + func WithHTTPClient(h *http.Client) Option + func WithLogger(l *log.Logger) Option + func WithRetryMaxAttempts(n int) Option + func WithRetryMutations() Option + func WithRetryPolicy(p RetryPolicy) Option + func WithSleeper(s clock.Sleeper) Option + func WithTimeout(d time.Duration) Option + func WithUserAgent(ua string) Option + type Page struct + Data []T + Pagination Pagination + func (p Page[T]) HasMore() bool + type Pagination struct + NextPageToken *string + PageSize json.Number + type Pipeline struct + CreatedAt time.Time + Definition PipelineDefinition + Name string + ProjectID string + ResourceSize string + Status PipelineStatus + Type string + UpdatedAt time.Time + Version json.Number + type PipelineDefinition struct + Description string + Job bool + ResourceSize string + Sinks map[string]any + Sources map[string]any + Transforms map[string]any + UseDedicatedIP bool + type PipelineErrorCountResponse struct + Data struct{ ... } + type PipelineLogsOptions struct + After *float64 + Cursor *float64 + Direction string + LogLevels string + Search string + type PipelineLogsResponse struct + Data LogResults + type PipelinePager struct + func (p *PipelinePager) NextPage(ctx context.Context) (Page[Pipeline], error) + type PipelineService struct + func (s *PipelineService) Create(ctx context.Context, req CreatePipelineRequest) (Pipeline, error) + func (s *PipelineService) Delete(ctx context.Context, name string) error + func (s *PipelineService) ErrorCount(ctx context.Context, name string, sinceHours int) (PipelineErrorCountResponse, error) + func (s *PipelineService) Get(ctx context.Context, name string) (Pipeline, error) + func (s *PipelineService) List(ctx context.Context, opts ListPipelinesOptions) (Page[Pipeline], error) + func (s *PipelineService) Logs(ctx context.Context, name string, opts PipelineLogsOptions) (PipelineLogsResponse, error) + func (s *PipelineService) NewPipelinePager(opts ListPipelinesOptions) *PipelinePager + func (s *PipelineService) Pause(ctx context.Context, name string) error + func (s *PipelineService) Preview(ctx context.Context, req PreviewPipelineRequest) (PreviewPipelineResponse, error) + func (s *PipelineService) Restart(ctx context.Context, name string, req *RestartPipelineRequest) error + func (s *PipelineService) Resume(ctx context.Context, name string) error + func (s *PipelineService) State(ctx context.Context, name string) (PipelineStateResponse, error) + func (s *PipelineService) Status(ctx context.Context, name string) (PipelineStatusResponse, error) + func (s *PipelineService) Validate(ctx context.Context, req ValidatePipelineRequest) (ValidatePipelineResponse, error) + type PipelineStateResponse struct + Data json.RawMessage + type PipelineStatus string + const PipelineStatusDeploying + const PipelineStatusFailed + const PipelineStatusPaused + const PipelineStatusRestarting + const PipelineStatusRunning + const PipelineStatusStopped + const PipelineStatusSucceeded + const PipelineStatusUnknown + type PipelineStatusResponse struct + Errors []struct{ ... } + Name string + Status PipelineStatus + type PreviewPipelineRequest struct + Definition PipelineDefinition + TTLSeconds json.Number + type PreviewPipelineResponse struct + ExpiresAt time.Time + PipelineName string + TTLSeconds json.Number + type ProblemDetails struct + Detail string + Errors []ValidationError + Headers http.Header + Instance string + RawBody []byte + Status int + Title string + Type string + func AsProblem(err error) *ProblemDetails + func (e *ProblemDetails) Error() string + func (e *ProblemDetails) Is(target error) bool + func (e *ProblemDetails) IsAuthentication() bool + func (e *ProblemDetails) IsConflict() bool + func (e *ProblemDetails) IsNotFound() bool + func (e *ProblemDetails) IsPermission() bool + func (e *ProblemDetails) IsRateLimited() bool + func (e *ProblemDetails) IsServerError() bool + func (e *ProblemDetails) IsSubscription() bool + func (e *ProblemDetails) IsUnprocessable() bool + func (e *ProblemDetails) IsValidation() bool + func (e *ProblemDetails) RetryAfter() (seconds int, ok bool) + type RPCBatchCall struct + Method string + Params any + Result any + type RPCError struct + Code int + Data json.RawMessage + Message string + func (e *RPCError) Error() string + type RPCResponse struct + Error *RPCError + ID int64 + JSONRPC string + Result json.RawMessage + type RPCService struct + func (s *RPCService) Batch(ctx context.Context, chainID int64, calls []RPCBatchCall) ([]RPCResponse, error) + func (s *RPCService) Call(ctx context.Context, chainID int64, method string, params any, result any) error + func (s *RPCService) EndpointURL(chainID int64) string + type RestartPipelineRequest struct + ClearState bool + type RetryPolicy struct + InitialBackoff time.Duration + MaxAttempts int + MaxBackoff time.Duration + RetryMutations bool + func DefaultRetryPolicy() RetryPolicy + type RevealEdgeKeyResponse struct + Data struct{ ... } + type SetSubgraphTagRequest struct + TargetVersion string + type Subgraph struct + Deployments []SubgraphDeployment + Description *string + GraphQLEndpoint string + Health SubgraphHealth + Name string + Network string + PrivateEndpointEnabled bool + PrivateGraphQLEndpoint string + PublicEndpointEnabled bool + Status SubgraphStatus + Synced bool + Tag *SubgraphTag + Version string + type SubgraphChainsResponse struct + Data struct{ ... } + type SubgraphDeployment struct + CreatedAt time.Time + DeploymentID string + FatalError *string + Health SubgraphHealth + IndexingProgress *IndexingProgress + NonFatalErrors []string + Synced bool + type SubgraphHealth string + const SubgraphHealthFailed + const SubgraphHealthHealthy + const SubgraphHealthUnhealthy + const SubgraphHealthUnknown + type SubgraphLogsOptions struct + After *float64 + Cursor *float64 + Direction string + LogLevel string + LogLevels string + Search string + type SubgraphLogsResponse struct + Data LogResults + type SubgraphPager struct + func (p *SubgraphPager) NextPage(ctx context.Context) (Page[Subgraph], error) + type SubgraphService struct + func (s *SubgraphService) DeleteDeployment(ctx context.Context, name, version string) error + func (s *SubgraphService) DeleteTag(ctx context.Context, name, version string) error + func (s *SubgraphService) Deploy(ctx context.Context, name, version string, opts DeploySubgraphOptions) (Subgraph, error) + func (s *SubgraphService) Get(ctx context.Context, name string) (Page[Subgraph], error) + func (s *SubgraphService) GetVersion(ctx context.Context, name, version string) (Page[Subgraph], error) + func (s *SubgraphService) List(ctx context.Context, opts ListSubgraphsOptions) (Page[Subgraph], error) + func (s *SubgraphService) Logs(ctx context.Context, name, version string, opts SubgraphLogsOptions) (SubgraphLogsResponse, error) + func (s *SubgraphService) NewSubgraphPager(opts ListSubgraphsOptions) *SubgraphPager + func (s *SubgraphService) Pause(ctx context.Context, name, version string) error + func (s *SubgraphService) Resume(ctx context.Context, name, version string) error + func (s *SubgraphService) SetTag(ctx context.Context, name, version string, req SetSubgraphTagRequest) (Subgraph, error) + func (s *SubgraphService) SupportedChains(ctx context.Context) (SubgraphChainsResponse, error) + func (s *SubgraphService) UpdateVersion(ctx context.Context, name, version string, req UpdateSubgraphVersionRequest) (Subgraph, error) + func (s *SubgraphService) WebhookEntities(ctx context.Context, name, version string) (WebhookEntitiesResponse, error) + type SubgraphStatus string + const SubgraphStatusActive + const SubgraphStatusPaused + type SubgraphTag struct + TargetVersion string + type TransportError struct + Err error + Op string + StatusCode int + func AsTransport(err error) *TransportError + func (e *TransportError) Error() string + func (e *TransportError) Unwrap() error + type UpdateEdgeEndpointRequest struct + AllowedDomains []string + RateLimitBudget *EdgeRateLimitBudget + type UpdateSubgraphVersionRequest struct + Description *string + PrivateEndpointEnabled *bool + PublicEndpointEnabled *bool + type ValidatePipelineRequest struct + Definition PipelineDefinition + Description string + Name string + ResourceSize string + UseDedicatedIP *bool + type ValidatePipelineResponse struct + Errors []ValidationMessage + Valid bool + Warnings []ValidationMessage + type ValidationError struct + Field string + Message string + type ValidationMessage struct + Field string + Message string + type Webhook struct + CreatedAt time.Time + Entity string + ID string + Name string + SubgraphName string + SubgraphVersion string + WebhookURL string + type WebhookEntitiesResponse struct + Data struct{ ... } + type WebhookEntity struct + Columns []WebhookEntityColumn + Name string + Rows string + type WebhookEntityColumn struct + DataType string + Name string + type WebhookListResponse struct + Data []Webhook + type WebhookService struct + func (s *WebhookService) Create(ctx context.Context, req CreateWebhookRequest) (CreateWebhookResponse, error) + func (s *WebhookService) Delete(ctx context.Context, name string) error + func (s *WebhookService) List(ctx context.Context) (WebhookListResponse, error)