Help us shape the future of Go! Take the 2026 Go Developer Survey

api

package
v0.1.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Oct 20, 2026 License: BSD-2-Clause Imports: 13 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type API

type API struct {
	// contains filtered or unexported fields
}

func New

func New(workflows Workflows, publisher Publisher, executions Executions, catalog Catalog, resumer Resumer, nodeTypes NodeTypes) *API

func (*API) Register

func (a *API) Register(app *fiber.App, token string)

type Catalog

type Catalog interface {
	Save(ctx context.Context, definition *models.EventDefinition) error
	Get(ctx context.Context, key string) (*models.EventDefinition, error)
	List(ctx context.Context) ([]*models.EventDefinition, error)
}

type Executions

type Executions interface {
	GetExecutionContext(ctx context.Context, executionID string) (*models.ExecutionContext, error)
	GetExecutionsByWorkflow(ctx context.Context, workflowID string, limit int) ([]*models.ExecutionContext, error)
}

type NodeTypes

type NodeTypes interface {
	Save(ctx context.Context, nodeType *models.RemoteNodeType) error
	Get(ctx context.Context, id string) (*models.RemoteNodeType, error)
}

type Publisher

type Publisher interface {
	PublishWorkflow(ctx context.Context, workflowID string) (*models.Workflow, error)
}

type Resumer

type Resumer interface {
	Resume(ctx context.Context, executionID, nodeID string, data map[string]any) error
}

type Workflows

type Workflows interface {
	FetchAll(ctx context.Context, tenantID string) ([]*models.Workflow, error)
	FetchByID(ctx context.Context, id string) (*models.Workflow, error)
	Create(ctx context.Context, workflow *models.Workflow) (*models.Workflow, error)
}

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL