Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶
type Config struct {
// contains filtered or unexported fields
}
Config holds configuration for creating Connect RPC clients.
func NewConfig ¶
func NewConfig(httpClient connect.HTTPClient, options ...ConfigOption) *Config
NewConfig creates a new client configuration with the given HTTP client and options.
type ConfigOption ¶
type ConfigOption func(*Config)
ConfigOption is an option for customizing a new Config.
func WithAddressMapper ¶
func WithAddressMapper(addressMapper func(string) string) ConfigOption
WithAddressMapper maps the address with the given function.
func WithAuthInterceptorProvider ¶
func WithAuthInterceptorProvider(authInterceptorProvider func(string) connect.UnaryInterceptorFunc) ConfigOption
WithAuthInterceptorProvider configures a provider that, when invoked, returns an interceptor that can be added to a client for setting the auth token
func WithInterceptors ¶
func WithInterceptors(interceptors []connect.Interceptor) ConfigOption
WithInterceptors adds the slice of interceptors to all clients returned from this provider.
type StubFactory ¶
StubFactory is the type of a generated factory function, for creating Connect client stubs.
Click to show internal directories.
Click to hide internal directories.