Documentation ¶
Overview ¶
Package storeid contains middleware to inject and manage the store ID context.
Index ¶
Constants ¶
View Source
const ( // StoreIDHeader represents the HTTP header name used to // specify the OpenFGA store identifier in API requests. StoreIDHeader string = "Openfga-Store-Id" )
Variables ¶
This section is empty.
Functions ¶
func NewStreamingInterceptor ¶
func NewStreamingInterceptor() grpc.StreamServerInterceptor
NewStreamingInterceptor creates a grpc.StreamServerInterceptor which injects store_id metadata into the RPC context if an RPC message is received with a GetStoreId method.
func NewUnaryInterceptor ¶
func NewUnaryInterceptor() grpc.UnaryServerInterceptor
NewUnaryInterceptor creates a grpc.UnaryServerInterceptor which injects store_id metadata into the RPC context if an RPC message is received with a GetStoreId method.
func SetStoreIDInContext ¶
SetStoreIDInContext sets the store ID in the provided context based on information from the request.
Types ¶
This section is empty.
Click to show internal directories.
Click to hide internal directories.