typesafe

package
v0.66.0 Latest Latest
Warning

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

Go to latest
Published: Oct 30, 2026 License: MIT Imports: 10 Imported by: 0 modules, 0 packages

The first number is the count of modules that contain a package that imports this one. The module count is a better indicator of popularity than the package count. A module with 100 importing packages is counted only once instead of 100 times, reflecting the fact that the choice to use the package was likely made only once, not 100 times.
A '?' means that the value hasn't been computed yet.

Documentation

Index

Constants

View Source
const (
	ProviderID = "typesafe"
)

Variables

This section is empty.

Functions

This section is empty.

Types

type Config

type Config struct {
	BaseURL      string `json:"base_url,omitempty"`
	APIKey       string `json:"api_key,omitempty"`
	APIKeyHelper string `json:"api_key_helper,omitempty"`
}

type Evaluator

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

func New

func New(cfg Config) (*Evaluator, error)

func NewWithProvider

func NewWithProvider(cfg Config, providerID, fallbackURL string) (*Evaluator, error)

NewWithProvider builds an evaluator for any SystemOne-compatible provider, allowing callers to override the provider ID and default base URL.

func (*Evaluator) Evaluate

func (e *Evaluator) Evaluate(ctx context.Context, req decision.Request) (decision.Response, error)

func (*Evaluator) ID

func (e *Evaluator) ID() string

type Factory

type Factory struct{}

func (Factory) ID

func (Factory) ID() string

func (Factory) New

func (Factory) New(rawConfig json.RawMessage) (decision.Evaluator, error)

Jump to

Keyboard shortcuts

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