Versions in this module Expand all Collapse all v0 v0.1.1 Oct 19, 2026 v0.1.0 Oct 18, 2026 Changes in this version + func GatedFunc(client *Client, action string, fn func() (interface{}, error)) (interface{}, error) + func GatedFuncWithContext(ctx context.Context, client *Client, action string, target string, ...) (interface{}, error) + func HTTPMiddleware(client *Client, opts *GatedOptions) func(http.Handler) http.Handler + type ApprovalRequiredError struct + Action string + DecisionID string + FlowID string + func (e *ApprovalRequiredError) Error() string + type Client struct + func NewClient(config *ClientConfig) (*Client, error) + func (c *Client) Evaluate(ctx context.Context, action string, target string, actor string, ...) (*GateResult, error) + func (c *Client) Gate(ctx context.Context, action string, target string, actor string, ...) (*GateResult, error) + func (c *Client) WaitForApproval(ctx context.Context, flowID string) (string, error) + type ClientConfig struct + APIKey string + ApprovalTimeout int + BaseURL string + PollInterval int + Timeout int + type ExecutionAuthorizationRequiredError struct + Action string + FlowID string + func (e *ExecutionAuthorizationRequiredError) Error() string + type GateBlockedError struct + Action string + DecisionID string + Reason string + func (e *GateBlockedError) Error() string + type GateDecision string + const Allowed + const ApprovalRequired + const Blocked + type GateHandler func(ctx context.Context) (interface{}, error) + func Gate(client *Client, opts *GatedOptions, handler GateHandler) GateHandler + type GateResult struct + Decision GateDecision + DecisionID string + FlowID string + Raw map[string]interface{} + Reason string + ReviewDeadline string + RiskScore *float64 + TrustScore *float64 + type GatedOptions struct + Action string + Client *Client + OnBlock func(error *GateBlockedError) interface{} + Target string + WaitForApproval bool + type QerexaError struct + Message string + func (e *QerexaError) Error() string