Documentation
¶
Index ¶
- func AnyRegionForContext(ctx context.Context) string
- func CityForContext(ctx context.Context) string
- func IPForContext(ctx context.Context) string
- func RegionForContext(ctx context.Context) string
- func StoreRegionForContext(ctx context.Context) string
- func WithCity(ctx context.Context, city string) context.Context
- func WithIP(ctx context.Context, ip string) context.Context
- func WithRegion(ctx context.Context, region string) context.Context
- func WithStoreRegion(ctx context.Context, region string) context.Context
- type ClientMiddleware
- type ContextKey
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func AnyRegionForContext ¶
AnyRegionForContext extract store region or client if not present
func RegionForContext ¶
RegionForContext extract region with priority over
func StoreRegionForContext ¶
StoreRegionForContext extract store region
func WithRegion ¶
WithRegion build a context with a given region
Types ¶
type ClientMiddleware ¶
ClientMiddleware is a custom type for our middleware
func NewClientMiddleware ¶
func NewClientMiddleware() ClientMiddleware
NewClientMiddleware create a ClientMiddleware
type ContextKey ¶
type ContextKey string
ContextKey represents a context key for authentication context values
Click to show internal directories.
Click to hide internal directories.