Documentation
¶
Overview ¶
Package cloudflareworkers provides Cloudflare Workers AI's documented OpenAI-compatible AI Gateway route.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func NewCounter ¶
func NewCounter(_ auth.APIKey) (contextcount.ContextCounter, error)
Types ¶
type ConfigurationError ¶
type ConfigurationError struct {
Reason ConfigurationReason
}
func (*ConfigurationError) Error ¶
func (e *ConfigurationError) Error() string
type ConfigurationReason ¶
type ConfigurationReason string
const AccountMissing ConfigurationReason = "account ID is missing"
type Option ¶
type Option func(*config)
func WithAccountID ¶
WithAccountID sets the Cloudflare account used when Model.BaseURL is empty.
func WithGatewayID ¶
WithGatewayID selects an AI Gateway when Workers AI is routed through one.
func WithHeader ¶
Click to show internal directories.
Click to hide internal directories.