View Source API Reference Unleash v3.0.0

Modules

Unofficial Elixir SDK for the Unleash Feature Flag System.

This module is a cache backed by an ETS table. We use it to allow for multiple threads to read the feature flag values concurrently on top of minimizing network calls

HTTP Client responsible for communicating with the Unleash API Server.

The Unleash Context, mostly used to evaluate conditional activation strategies. https://docs.getunleash.io/reference/unleash-context.

This module offers a macro API over the Unleash behaviour, and should be used as the main entrypoint over the Unleash SDK.

GenServer responsible for reporting metrics to the Unleash API Server.

An extra fancy Plug and utility functions to help when developing Plug or Phoenix-based applications. It automatically puts together a Unleash.context/0 and stores it in the t:Plug.Conn.t()'s assigns.

The Unleash Propagation mechanism enables the propagation of feature flag contexts, overrides, and impressions throughout a distributed system, similarly to how OpenTelemetry helps propagate Trace Contexts to build distributed traces.

A gRPC Client Interceptor designed to propagate Unleash context and overrides downstream.

A GRPC Server Interceptor to extract unleash context and overrides from incoming GRPC request headers and store them for feature flag checks and further propagation downstream (e.g. via Unleash.Propagation.GRPC.ContextClientInterceptor).

a gRPC Client Interceptor to automatically backpropagate impressions returned by downstream gRPC services. Client-side counterpart of Unleash.Propagation.GRPC.ImpressionsServerInterceptor.

A GRPC Server Interceptor to automatically track feature impressions while handling the request, and return them back to the caller in the response headers.

Module that defines plugs to automatically integrate with the Unleash.Propagation mechanism.

Module handling the (de)serialization of Unleash objects for propagation. See Unleash.Propagation.

An error representing context deserialization failure.

An error representing context serialization failure.

An error representing impressions deserialization failure.

An error representing overrides deserialization failure.

An error representing overrides serialization failure.

This genserver polls the unleash service each time the given interval has elapsed, refreshing both our local ETS cache and the backup state file if the flag state has diverged.

Main Runtime implementation for the Unleash SDK.

Used to get all available strategies in the client. You can add your strategies to the client by extending this module

Used to extend the client and create custom strategies. To do so, use this module within your custom strategy and implmenent enabled?/2. Provide a name that is human-readable, as it is logged.

Module that is used to verify constraints are met.

Does not require anything in Unleash.context/0

Can depend on :user_id or :session_id in Unleash.context/0

Utilities that might help you create your own strategies.

Defines types and functions for representing and working with strategy and feature variants.