1
0
mirror of https://github.com/Unleash/unleash.git synced 2025-07-26 13:48:33 +02:00

docs: updates to Unleash Frontend API docs and Unleash architecture overview (#9513)

This commit is contained in:
Melinda Fekete 2025-04-07 12:38:00 +02:00 committed by GitHub
parent 3e1d873153
commit 5ed3041b11
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
15 changed files with 227 additions and 159 deletions

View File

@ -68,7 +68,7 @@ const OPENAPI_TAGS = [
{
name: 'Frontend API',
description:
'API for connecting client-side (frontend) applications to Unleash.',
'The [Frontend API](https://docs.getunleash.io/reference/front-end-api) is used for connecting client-side (frontend) applications to Unleash.',
},
{
name: 'Import/Export',

View File

@ -63,7 +63,7 @@ These parts turn the constraint into an expression that evaluates to true or fal
#### Constraint operators
Constraint operators help you define the conditional statements that get evaluated as part of the constraint. [Basic operators](#basic-operators) are available in all versions and SDKs. All other operators require Unleash version 4.9+ and [SDK compatibility](/reference/sdks#server-side-sdk-compatibility-table).
Constraint operators help you define the conditional statements that get evaluated as part of the constraint. [Basic operators](#basic-operators) are available in all versions and SDKs. All other operators require Unleash version 4.9+ and [SDK compatibility](/reference/sdks#feature-compatibility-in-server-side-sdks).
All constraints can be negated. For example:
@ -72,14 +72,15 @@ All constraints can be negated. For example:
| `STR_ENDS_WITH` | "@user.com" | "hello@user.com" | true |
| NOT `STR_ENDS_WITH` | "@user.com" | "hello@user.com" | false |
##### Basic operators
#### Basic operators
| Operator | Description
|-----------|--------------------------------------------------------------------------------|
| `IN` | The context field is equal to any of the provided values; case sensitive. |
| `NOT_IN` | The context field is not equal to any of the values provided; case sensitive. |
#### Numeric operators
#### Advanced operators
##### Numeric operators
Numeric operators compare the numeric value of context fields with the provided value. Numeric operators only accept single values.

View File

@ -171,4 +171,4 @@ To designate a string as a proxy client key, add it to the `clientKeys` list whe
:::
Proxy client keys cannot be used to connect to the Unleash API; use [API tokens](#api-tokens) instead.
Proxy client keys cannot be used to connect to the Unleash API; use API tokens instead.

View File

@ -128,7 +128,7 @@ If an archived feature is revived, it starts a new lifecycle with a new [Define]
**Plan**: [Pro](/availability#plans) and [Enterprise](https://www.getunleash.io/pricing)
**Unleash version**: `5.7+` | **Unleash Edge version**: `13.1+` | **Unleash Proxy version**: `0.18+`. Requires [SDK compatibility](../reference/sdks#server-side-sdk-compatibility-table) for variants.
**Unleash version**: `5.7+` | **Unleash Edge version**: `13.1+` | **Unleash Proxy version**: `0.18+`. Requires [SDK compatibility](../reference/sdks#feature-compatibility-in-server-side-sdks) for variants.
:::
Feature flag dependencies define a relationship between feature flags. Each feature flag can have one parent, but multiple child flags can share the same parent.

View File

@ -8,41 +8,30 @@ title: Frontend API
:::
The Unleash Frontend API offers a simplified workflow for connecting client-side applications to Unleash. It provides the exact same API as [Unleash Edge](https://docs.getunleash.io/reference/unleash-edge) and [Unleash Proxy - deprecated](../generated/unleash-proxy.md). The Frontend API is a quick and easy way to add Unleash to single-page applications and mobile apps.
## Overview
Compared to using Unleash Edge, using the Frontend API has both benefits and drawbacks. The benefits are:
The Unleash [Frontend API](/reference/api/unleash/frontend-api) simplifies connecting client-side applications to Unleash. [Unleash Edge](https://docs.getunleash.io/reference/unleash-edge) also implements this API allowing you to scale from development environments, low-traffic applications, or internal dashboards to a production-ready scalable solution.
- **You don't need to configure and run Unleash Edge.** The Frontend API is part of Unleash itself and not an external process. All clients will work exactly the same as they would with Unleash Edge.
The Frontend API has a straightforward setup, and since it is built directly into Unleash, you don't need to manage it. However, unlike Unleash Edge, it cannot be scaled horizontally and isnt designed for high request volumes.
On the other hand, using the Frontend API has the following drawbacks compared to using Unleash Edge:
Since the Frontend API shares the same API as Unleash Edge, you can start development with the Frontend API and transition to Unleash Edge when needed.
- **It can't handle a large number of requests per second.** Because the Frontend API is part of Unleash, you can't scale it horizontally the way you can scale Unleash Edge.
- **It sends client details to your Unleash instance.** Unleash only stores these details in its short-term runtime cache, but this can be a privacy issue for some use cases.
## Configure the Frontend API
These points make the Unleash Frontend API best suited for development purposes and applications that dont receive a lot of traffic, such as internal dashboards. However, because the API is identical to the Unleash Edge API, you can go from one to the other at any time. As such, you can start out by using the Frontend API and switch to Unleash Edge when you need it.
### Configure cross-origin resource sharing (CORS)
## Using the Unleash Frontend API
For web and hybrid mobile apps, allow traffic from your application's domains.
When using the Frontend API in an SDK, there's three things you need to configure.
For Unleash, you can update CORS settings in the Unleash Admin UI in **Admin > CORS origins**. For Unleash Edge, follow our [command-line for CORS settings](https://github.com/Unleash/unleash-edge/blob/243cfbdf2ef5f78a7312db6cc688cc74b7d5f318/CLI.md).
### Cross-origin resource sharing (CORS) configuration {#cors}
### Configure the API URL
You need to allow traffic from your application domains to use the Unleash Frontend API with web and hybrid mobile applications. You can update the Frontend API CORS settings from the Unleash UI under _admin \> CORS_ or by using the API.
Point your application to the correct API endpoint: `<your-unleash-instance>/api/frontend`.
### API URL
### Generate an API token
The client needs to point to the correct API endpoint. The Frontend API is available at `<your-unleash-instance>/api/frontend`.
Your application needs a [frontend token](../reference/api-tokens-and-client-keys.mdx#frontend-tokens) to interact with the Frontend API.
<!-- Point to the API docs when they're published -->
### Configure the refresh interval for tokens
### API token
The client needs a frontend [token](../reference/api-tokens-and-client-keys.mdx#frontend-tokens) to interact with the Frontend API.
### Refresh interval for tokens
Internally, Unleash creates a new Unleash client for each token it receives. Each client is configured with the project and environment specified in the token.
Each client updates its feature flag configuration at a specified refresh interval plus a random offset between 0 and 10 seconds. By default, the refresh interval is set to 10 seconds. The random offset is used to stagger incoming requests to avoid a large number of clients all querying the database simultaneously. A new, random offset is used for every update.
The refresh interval is specified in milliseconds and can be set by using the `FRONTEND_API_REFRESH_INTERVAL_MS` environment variable or by using the `frontendApi.refreshIntervalInMs` configuration option in code.
Feature flag updates occur at a default refresh interval of 10 seconds plus a random offset (0-10 seconds) to prevent simultaneous database queries. You can customize the refresh interval using the `FRONTEND_API_REFRESH_INTERVAL_MS` environment variable or the `frontendApi.refreshIntervalInMs` configuration option in the SDK.

View File

@ -5,7 +5,7 @@ pagination_next: reference/events
:::note Availability
**Version**: `4.7+`. Requires [SDK compatibility](../reference/sdks#server-side-sdk-compatibility-table).
**Version**: `4.7+`. Requires [SDK compatibility](../reference/sdks#feature-compatibility-in-server-side-sdks).
:::

View File

@ -103,7 +103,7 @@ You can assign the following root permissions:
|---------------------|------------------------------------|
| Change instance banners | Change instance [banners](./banners). |
| Change maintenance mode state | Change [maintenance mode](./maintenance-mode) state. |
| Update CORS settings | Update [CORS settings](./front-end-api#cors). |
| Update CORS settings | Update [CORS settings](./front-end-api#configure-cross-origin-resource-sharing-cors). |
| Read instance logs and login history | Read instance logs and [login history](./login-history.md). |
#### Integration permissions

View File

@ -2,19 +2,20 @@
title: SDK overview
---
import VideoContent from '@site/src/components/VideoContent.jsx'
Unleash offers a number of client libraries (SDKs) designed to help you integrate Unleash into your applications. The SDKs provide an interface for fetching and evaluating feature flags.
To connect your application to Unleash you need a [client SDK](#official-sdks) for your programming language and an [API token](./api-tokens-and-client-keys). The SDK handles connecting to the Unleash server instance and retrieving feature flags based on your configuration. All versions of Unleash (OSS, Pro, and Enterprise) use the same client SDKs.
With [Unleash's architecture](../understanding-unleash/unleash-overview#system-overview), feature flags can be evaluated within the SDKs or [Unleash Edge](./unleash-edge), making evaluations incredibly fast. SDKs cache feature flag data in memory, providing high reliability.
Unleash provides official client SDKs for a number of programming languages. Additionally, our community has developed and contributed SDKs for other languages. So if you can't find your favorite language in the list of official SDKs, check out the [list of clients written by our fantastic community](#community-sdks).
Unleash provides official SDKs for a number of programming languages. Our community has also contributed SDKs for [additional languages](#community-sdks).
## Official SDKs
<VideoContent videoUrls={["https://www.youtube.com/embed/mCXSAWzdn3I"]}/>
### Server-side SDKs
### Server-side SDKs:
Serverside SDKs run in backend services. They communicate with Unleash or [Unleash Edge](./unleash-edge) using the [Client API](../understanding-unleash/unleash-overview#client-api) and require a [client token](./api-tokens-and-client-keys#client-tokens).
Server-side SDKs perform the flag evaluation locally, meaning all user data is retained within the SDK.
Server-side clients run on your server and communicate directly with your Unleash instance to evaluate your feature flags in their respective language. We provide these official clients:
Unleash offers the following server-side SDKs:
- [Go SDK](/docs/generated/sdks/server-side/go.md)
- [Java SDK](/docs/generated/sdks/server-side/java.md)
@ -27,97 +28,115 @@ Server-side clients run on your server and communicate directly with your Unleas
### Client-side SDKs
Client-side SDKs can connect to [Unleash Edge](/reference/unleash-edge) or to the [Unleash front-end API](../front-end-api.md), but _not_ to the regular Unleash client API.
Client-side SDKs are used in frontend and mobile applications. They communicate with Unleash or [Unleash Edge](./unleash-edge) through the [Frontend API](./front-end-api) and require a [frontend token](./api-tokens-and-client-keys#frontend-tokens). Unlike server-side SDKs, client-side SDKs do not perform the flag evaluation locally. Instead, they fetch all enabled feature flags for a given [Unleash Context](./unleash-context). The flag evaluation happens either in [Unleash Edge](./unleash-edge), or in the Unleash server, when using the [Frontend API](./front-end-api) directly.
When the SDK initializes, it sets up an in-memory repository and retrieves a list of all enabled flags and their variants in a single request. Once fetched, the SDK serves flag values from memory, without making additional requests. It periodically refreshes the list of enabled flags to keep the data up to date.
Unleash offers the following client-side SDKs:
- [Android SDK](/docs/generated/sdks/client-side/android-proxy.md)
- [Flutter Proxy SDK](/docs/generated/sdks/client-side/flutter.md)
- [iOS Proxy SDK](/docs/generated/sdks/client-side/ios-proxy.md)
- [Flutter SDK](/docs/generated/sdks/client-side/flutter.md)
- [iOS SDK](/docs/generated/sdks/client-side/ios-proxy.md)
- [JavaScript SDK](/docs/generated/sdks/client-side/javascript-browser.md)
- [Next.js](/docs/generated/sdks/client-side/next-js.md)
- [React Proxy SDK](/docs/generated/sdks/client-side/react.md)
- [Svelte Proxy SDK](/docs/generated/sdks/client-side/svelte.md)
- [Vue Proxy SDK](/docs/generated/sdks/client-side/vue.md)
- [React SDK](/docs/generated/sdks/client-side/react.md)
- [Svelte SDK](/docs/generated/sdks/client-side/svelte.md)
- [Vue SDK](/docs/generated/sdks/client-side/vue.md)
### Server-side SDK compatibility table
### Feature compatibility in server-side SDKs
The below table shows what features the various server-side SDKs support. Note that certain features make sense only for some clients due to how the programming language works or due to how the client works.
The following tables show which features are supported by each server-side SDK. Some features are only applicable to specific SDKs, depending on the programming language or how the client is implemented.
**Legend**:
**Symbol reference**
- ✅: Implemented
- ⭕: Not yet implemented, but we're looking into it
- ❌: Not implemented, not planned
- **N/A**: Not applicable to this SDK
✅ Implemented | ❌ Not supported | ⭕ Not implemented, but under consideration | **N/A** Not applicable to this SDK
:::note
#### Initialization
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| Async initialization | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ | ✅ |
| Block until synchronized | ✅ | ✅ | ✅ | ⭕ | ⭕ | ✅ | ✅ | ⭕ |
| Context provider | ✅ | N/A | N/A | N/A | N/A | ✅ | ✅ | N/A |
| Global fallback function | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ | ❌ | ❌ |
| Flag Query: `namePrefix`, `tags` | ✅ | ✅ | ❌ | ❌ | ❌ | ❌ | ✅ | ❌ |
| Flag Query: `project_name` | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | N/A | ⭕ |
If you see an item marked with a ❌ that you would find useful, feel free to reach out to us ([on Slack](https://slack.unleash.run/), for instance) with your use case. It may not be something we can prioritize right now, but if you'd like to contribute it back to the community, we'd love to help you build it.
#### Custom headers
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| static | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| function | ✅ | ✅ | ⭕ | ✅ | ✅ (4.3) | ✅ | ✅ | ⭕ |
:::
#### Built-in strategies
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| [Gradual rollout](./activation-strategies) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| [Gradual rollout with custom stickiness](./stickiness#custom-stickiness) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| [UserID](./predefined-strategy-types#userids), [IP](./predefined-strategy-types#ips), [hostname](./predefined-strategy-types#hosts) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| [IP](./predefined-strategy-types#ips) with CIDR syntax | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ | ✅ | ✅ |
#### Custom strategies
All server-side SDKs have basic support.
#### Strategy constraints
All server-side SDKs have support for the basic operators (`IN`, `NOT_IN`).
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| **Category: Initialization** | | | | | | | | |
| Async initialization | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ❌ | ✅ |
| Can block until synchronized | ✅ | ✅ | ✅ | ⭕ | ⭕ | ✅ | ✅ | ⭕ |
| [Advanced operators](./activation-strategies#advanced-operators) | ✅ (5.1) | ✅ (3.12) | ✅ (3.3) | ✅ (5.1) | ✅ (4.2) | ✅ (2.1) | ✅ (1.3.1) | ⭕ |
#### Unleash Context
Static fields (`environment`, `appName`), defined fields, and custom properties are supported in all server-side SDKs.
#### `isEnabled` implementation
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| Can take context and override fallback value | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Fallback function | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ | ⭕ | ⭕ |
#### Strategy variants
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| [Strategy variants](./strategy-variants) and [custom stickiness](./stickiness#custom-stickiness) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
#### Local backup
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| File-based local backup | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
#### Metrics and impression data
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| Usage metrics | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| [Impression data](./impression-data) | ✅ | ✅ | ⭕ | ✅ | ⭕ | ✅ | ✅ | ⭕ |
#### Bootstrap
| Capability | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| Bootstrap from file or custom implementation | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
### Default refresh and metrics intervals
#### Server-side SDKs
| Interval | [Java](/docs/generated/sdks/server-side/java.md) | [Node.js](/docs/generated/sdks/server-side/node.md) | [Go](/docs/generated/sdks/server-side/go.md) | [Python](/docs/generated/sdks/server-side/python.md) | [Ruby](/docs/generated/sdks/server-side/ruby.md) | [.NET](/docs/generated/sdks/server-side/dotnet.md) | [PHP](/docs/generated/sdks/server-side/php.md) | [Rust](/docs/generated/sdks/server-side/rust.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| Default refresh interval | 15s | 15s | 15s | 15s | 15s | 15s | 15s | 15s |
| Default metrics interval | 60s | 60s | 60s | 60s | 60s | 60s | 60s | 15s |
| Context provider | ✅ | N/A | N/A | N/A | N/A | ✅ | ✅ | N/A |
| Global fallback function | ✅ | ✅ | ✅ | ✅ | ❌ | ❌ | ❌ | ❌ |
| Flag Query: `namePrefix` | ✅ | ✅ | ❌ | ❌ | ❌ | ❌ | ✅ | ❌ |
| Flag Query: `tags` | ✅ | ✅ | ❌ | ❌ | ❌ | ❌ | ✅ | ❌ |
| Flag Query: `project_name` | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | N/A | ⭕ |
| **Category: Custom Headers** | | | | | | | | |
| static | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| function | ✅ | ✅ | ⭕ | ✅ | ✅ (4.3) | ✅ | ✅ | ⭕ |
| **Category: Built-in strategies** | | | | | | | | |
| [Gradual rollout](./activation-strategies) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| [Gradual rollout: custom stickiness](./stickiness#custom-stickiness) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| [UserID](./predefined-strategy-types#userids) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| [IP](./predefined-strategy-types#ips) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| [IP](./predefined-strategy-types#ips): CIDR syntax | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ | ✅ | ✅ |
| [Hostname](./predefined-strategy-types#hosts) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| **Category: [Custom strategies](./custom-activation-strategies)** | | | | | | | | |
| Basic support | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| <span id="strategy-constraints">**Category: [Strategy constraints](./activation-strategies#constraints)**</span> | | | | | | | | |
| Basic support (`IN`, `NOT_IN` operators) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| <span id="strategy-constraints-advanced-support">Advanced support (Semver, date, numeric, and extended string operators)</span> (introduced in) | ✅ (5.1) | ✅ (3.12) | ✅ (3.3) | ✅ (5.1) | ✅ (4.2) | ✅ (2.1) | ✅ (1.3.1) | ⭕ |
| **Category: [Unleash Context](./unleash-context)** | | | | | | | | |
| Static fields (`environment`, `appName`) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Defined fields | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Custom properties | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| **Category: [`isEnabled`](/client-specification#implementation-of-isenabled)** | | | | | | | | |
| Can take context | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Override fallback value | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Fallback function | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ | ⭕ | ⭕ |
| **Category: [Variants](./feature-toggle-variants)** | | | | | | | | |
| Basic support | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Custom fallback variant | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| Custom weight | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| [Custom stickiness](./stickiness#custom-stickiness) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| [Strategy Variants](./strategy-variants)| ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| **Category: Local backup** | | | | | | | | |
| File-based backup | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| **Category: Usage metrics** | | | | | | | | |
| Can disable metrics | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Client registration | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| Basic usage metrics (yes/no) | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ |
| [Impression data](./impression-data) | ✅ | ✅ | ⭕ | ✅ | ⭕ | ✅ | ✅ | ⭕ |
| **Category: Bootstrap (beta)** | | | | | | | | |
| Bootstrap from file | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
| Custom Bootstrap implementation | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ✅ | ⭕ |
### Client-side SDK intervals
#### Client-side SDKs
| Interval | [Android](/docs/generated/sdks/client-side/android-proxy.md) | [Flutter](/docs/generated/sdks/client-side/flutter.md) | [iOS](/docs/generated/sdks/client-side/ios-proxy.md) | [JavaScript](/docs/generated/sdks/client-side/javascript-browser.md) | [Next.js](/docs/generated/sdks/client-side/next-js.md) | [React](/docs/generated/sdks/client-side/react.md) | [Svelte](/docs/generated/sdks/client-side/svelte.md) | [Vue](/docs/generated/sdks/client-side/vue.md) |
| --- | :-: | :-: | :-: | :-: | :-: | :-: | :-: | :-: |
| Default refresh interval | 60s | 30s | 15s | 30s | 30s | 30s | 30s | 30s |
| Default metrics interval | 60s | 30s | 30s | 60s | 60s | 60s | 60s | 60s |
## Community SDKs ❤️ {#community-sdks}
## Community SDKs
Here's some of the fantastic work our community has done to make Unleash work in even more contexts. If you still can't find your favorite language, let us know and we'd love to help you create the client for it!
If you need a language or framework not covered officially, explore our community contributions:
- Angular - TypeScript ([angular-unleash-proxy-client](https://github.com/Karelics/angular-unleash-proxy-client) by [Karelics](https://karelics.fi/unleash-feature-flags-with-gitlab/))
- Angular - TypeScript ([ngx-unleash-proxy-client](https://github.com/snowfrogdev/snowfrogdev/tree/main/packages/ngx-unleash-proxy-client))
@ -133,53 +152,52 @@ Here's some of the fantastic work our community has done to make Unleash work in
- PHP - Symfony ([Stogon/unleash-bundle](https://github.com/Stogon/unleash-bundle))
- React Native / Expo ([nunogois/unleash-react-native](https://github.com/nunogois/unleash-react-native))
- Solid ([nunogois/proxy-client-solid](https://github.com/nunogois/proxy-client-solid))
- _...your implementation for your favorite language._
### Implement your own SDK {#implement-your-own-sdk}
### Implement your own SDK
If you can't find an SDK that fits your requirements, you can also develop your own SDK. To make implementation easier, check out these resources:
- [Unleash Client Specifications](https://github.com/Unleash/client-specification) - Used by all official SDKs to make sure they behave correctly across different language implementations. This lets us verify that a gradual rollout to 10% of the users would affect the same users regardless of which SDK you're using.
- [Client SDK overview](/client-specification) - A brief, overall guide of the _Unleash Architecture_ and important aspects of the SDK role in it all.
- [Client SDK overview](/client-specification) - A brief guide of the _Unleash Architecture_ and important aspects of the SDK role in it all.
## Client-side SDK behavior
## Offline behavior
The following section details the behavior of frontend / client-side SDKs when initializing and fetching flags with respect to network connectivity.
Once they have been initialized, all Unleash clients continue to function without an internet connection or in the event that the Unleash server has an outage.
When the SDK is initialized in the application, an in-memory repository is set up and synchronized against the frontend API using the configured token and context. Note that the frontend API is hosted by either the Unleash Proxy/Edge or the upstream Unleash instance directly.
Because the SDKs and the Unleash Edge cache their feature flag states locally and only communicate with the Unleash server or Edge at predetermined intervals, a broken connection only means that they won't get any new updates.
1. All feature flag evaluation is performed by the Proxy/Edge or Unleash instance. A payload of all enabled flags and their variants (if applicable) is returned as a single request. Disabled flags are not included.
2. When a page inside the application requests a feature flag, the SDK will return the flag state from memory. No network connection to the frontend API is performed.
3. The SDK periodically syncs with the frontend API to retrieve the latest set of enabled flags
## Working offline
Once they have been initialized, all Unleash clients will continue to work perfectly well without an internet connection or in the event that the Unleash Server has an outage.
Because the SDKs and the Unleash Proxy/Edge cache their feature flag states locally and only communicate with the Unleash server (in the case of the server-side SDKs and the Proxy) or the Proxy/Edge (in the case of front-end SDKs) at predetermined intervals, a broken connection only means that they won't get any new updates.
Unless the SDK supports [bootstrapping](#bootstrapping), it _will_ need to connect to Unleash at startup to get its initial feature flag data set. If the SDK doesn't have a feature flag data set available, all flags will fall back to evaluating as disabled or as the specified default value (in SDKs that support that).
Unless the SDK supports [bootstrapping](#bootstrapping), it needs to connect to Unleash at startup to get its initial feature flag data set. If the SDK doesn't have a feature flag data set available, all flags fall back to evaluating as disabled or as the specified default value.
### Bootstrapping
By default, all SDKs reach out to the Unleash Server at startup to fetch their flag configuration. Additionally, some of the server-side SDKs and the Proxy (see the above [compatibility table](#server-side-sdk-compatibility-table)) also support _bootstrapping_, which allows them to get their flag configuration from a file, the environment, or other local resources. These SDKs can work without any network connection whatsoever.
By default, all SDKs reach out to the Unleash server at startup to fetch their flag configuration. Additionally, most of the [server-side SDKs](#server-side-sdk-compatibility-table) and Unleash Edge support bootstrapping, which allows them to get their flag configuration from a file, the environment, or other local resources. These SDKs can function without any network connection.
Bootstrapping is also supported by the following front-end client SDKs:
Bootstrapping is also supported by the following frontend SDKs:
- [Android SDK](/docs/generated/sdks/client-side/android-proxy.md)
- [JavaScript SDK](/docs/generated/sdks/client-side/javascript-browser.md)
- [React Proxy SDK](/docs/generated/sdks/client-side/react.md)
- [Svelte Proxy SDK](/docs/generated/sdks/client-side/svelte.md)
- [Vue Proxy SDK](/docs/generated/sdks/client-side/vue.md)
- [React SDK](/docs/generated/sdks/client-side/react.md)
- [Svelte SDK](/docs/generated/sdks/client-side/svelte.md)
- [Vue SDK](/docs/generated/sdks/client-side/vue.md)
### SDK identification headers
To identify which frontend and backend SDK instances are connected to Unleash, the following headers must be attached to all requests made by the SDK to the server (`/api/client` for backend SDKs and `/api/frontend` for frontend SDKs):
To identify which SDK instances are connected to Unleash, the following headers must be attached to all requests made by the SDK to the server (`/api/client` for backend SDKs and `/api/frontend` for frontend SDKs):
- `unleash-connection-id`: A unique identifier for the current SDK instance, automatically generated using the idiomatic unique identifier generator for the specific programming ecosystem (for example, `randomUUID` from `crypto` in Node.js). This connection ID represents a long-lived connection between the SDK and the Unleash server. An SDK should generate a new connection ID each time an SDK instance is instantiated (for example, when calling `new Unleash()` in a Node SDK). The same connection ID should be used for each request when an SDK instance polls the API. Additionally, there is a legacy `unleash-instanceid` header that is not implemented by all SDKs and can be overwritten by the client, which is the main reason `unleash-connection-id` was introduced.
- `unleash-sdk`: Provides information about the language/framework and version of the SDK making the request. The format is the language/framework followed by a colon and the semantic version of the SDK (for example, `unleash-client-java@10.0.1` or `unleash-client-node@6.4.4`). Each SDK implementation should use a platform-idiomatic method to read the version from a package manager and update it with each version release.
- `unleash-appname` (optional): Specifies the name of your application that is communicating with Unleash. This name is user-defined with some SDKs providing a default fallback value. For example, `billing-service`.
`unleash-connection-id`
- **Description**: A unique identifier for the current SDK instance.
- **Format**: Automatically generated using the idiomatic unique identifier generator for the specific programming ecosystem. For example, `randomUUID` from `crypto` in Node.js.
- **Additional information**: This connection ID represents a long-lived connection between the SDK and the Unleash server. An SDK should generate a new connection ID each time an SDK instance is instantiated (for example, when calling `new Unleash()` in a Node SDK).
The same connection ID should be used for each request when an SDK instance polls the API. This header replaces the legacy `unleash-instanceid` which can be overwritten by the client.
**Exceptions**: Backend SDKs used in short-lived request/response models (like Next.js server mode and PHP) should not provide the `unleash-connection-id` header.
> Backend SDKs used in short-lived request/response models (like Next.js server mode and PHP) should not provide this header.
`unleash-sdk`
- **Description**: Provides information about the language/framework and version of the SDK making the request.
- **Format**: The language/framework followed by the `@` symbol and the semantic version of the SDK. For example, `unleash-client-java@10.0.1` or `unleash-client-node@6.4.4`.
- **Additional information**: Each SDK implementation should use a platform-idiomatic method to read the version from a package manager and update it with each version release.
`unleash-appname` (Optional)
- **Description**: Specifies the name of your application that is communicating with Unleash.
- **Format**: User-defined with some SDKs providing a default fallback value. For example, `billing-service`.

View File

@ -20,7 +20,7 @@ For instance: When using the [gradual rollout activation strategy](../reference/
:::note Availability
**Plan**: [Enterprise](https://www.getunleash.io/pricing) | **Version**: `4.0+` and [SDK compatibility](../reference/sdks#server-side-sdk-compatibility-table).
**Plan**: [Enterprise](https://www.getunleash.io/pricing) | **Version**: `4.0+` and [SDK compatibility](../reference/sdks#feature-compatibility-in-server-side-sdks).
:::

View File

@ -6,7 +6,7 @@ import VideoContent from '@site/src/components/VideoContent.jsx'
:::note Availability
**Version**: `5.4+` and [SDK compatibility](/reference/sdks#server-side-sdk-compatibility-table).
**Version**: `5.4+` and [SDK compatibility](/reference/sdks#feature-compatibility-in-server-side-sdks).
:::
## Overview

View File

@ -24,7 +24,7 @@ The following table gives an overview of the fields' intended usage, their lifet
| `sessionId` | `string` | dynamic | The identifier of the current session. |
| `remoteAddress` | `string` | dynamic | The application's IP address. |
| `properties` | `Map<string, string>` | dynamic | A key-value store for additional data. |
| `currentTime` | `DateTime`/`string` | dynamic | A `DateTime` (or similar) data class instance or a string in an RFC-3339 format. **Defaults to the current time** if not set by the user; requires [SDK compatibility](../reference/sdks#server-side-sdk-compatibility-table). |
| `currentTime` | `DateTime`/`string` | dynamic | A `DateTime` (or similar) data class instance or a string in an RFC-3339 format. **Defaults to the current time** if not set by the user; requires [SDK compatibility](../reference/sdks#feature-compatibility-in-server-side-sdks). |
### The `properties` field
@ -74,7 +74,7 @@ Using a custom context field called _region_ as an example: if you define the fi
:::note SDK compatibility
Custom stickiness is supported by all SDKs except for the Rust SDK. Refer to the [SDK compatibility table](../reference/sdks#server-side-sdk-compatibility-table) for more information.
Custom stickiness is supported by all SDKs except for the Rust SDK. Refer to the [SDK compatibility table](../reference/sdks#feature-compatibility-in-server-side-sdks) for more information.
:::

View File

@ -2,7 +2,7 @@
title: Data and privacy
---
At Unleash, we prioritize the privacy and security of our customers' data. Our [architecture](/understanding-unleash/the-anatomy-of-unleash) ensures privacy by evaluating feature flags locally within the [client SDKs](/reference/sdks), meaning no user data is shared with the Unleash instance.
At Unleash, we prioritize the privacy and security of our customers' data. Our [architecture](/understanding-unleash/the-anatomy-of-unleash) ensures privacy by evaluating feature flags locally within the [client SDKs](/reference/sdks) or [Unleash Edge](/reference/unleash-edge), meaning no user data is shared with the Unleash instance.
:::info

View File

@ -2,31 +2,91 @@
title: Unleash architecture
---
One of the most important aspects of the Unleash architecture is that feature flags are evaluated directly in the client SDKs that run as part of your application. This makes flag evaluations incredibly fast (we're talking nanoseconds), scalable, and resilient against network disturbances. To achieve this, Unleash incurs a small update-delay when you change your flag configurations until it is fully propagated to your application. This delay is typically a few seconds and is configurable.
Unleash is designed for privacy, speed, and resilience, enabling feature flag evaluations to occur locally within your applications. The architecture provides:
- **Fast feature flag evaluations**: Feature flags are evaluated within the [SDKs](#unleash-sdks) or [Unleash Edge](#unleash-edge), making evaluations incredibly fast (nanoseconds).
- **Privacy and security**: No user data is shared with the Unleash server, ensuring [privacy and security](/understanding-unleash/data-collection).
- **High reliability**: SDKs cache feature flag data in memory, providing high reliability.
Since feature flags are evaluated locally within the [client SDKs](/reference/sdks), no user data is shared with the Unleash instance. This ensures complete privacy of your customer data.
## System Overview
If you want more details you can read about [our unique architecture](https://www.getunleash.io/blog/our-unique-architecture).
The Unleash system consists of several key components.
### Unleash Server {#unleash-server}
![A visual overview of an Unleash system as described in the following paragraph.](/img/unleash-architecture-edge.png)
Before you can connect your application to Unleash you need a Unleash server. You have a few options available:
### The Unleash API
1. **Unleash Open-Source**
- [Docker](../using-unleash/deploy/getting-started)
- [Helm Chart](https://github.com/unleash/helm-charts/)
- [GitLab](https://docs.gitlab.com/ee/operations/feature_flags.html#choose-a-client-library)
2. **Unleash Enterprise**
- [Hosted Plans](https://www.getunleash.io/plans)
- [Self-hosted](https://www.getunleash.io/blog/self-host-your-feature-toggle-system)
The Unleash API (or Unleash server) is the core service for managing feature flags, configurations, and related concepts. It provides SDKs with all the data needed to work with feature flags and their [activation strategies](/reference/activation-strategies).
### System Overview {#system-overview}
### The Unleash Admin UI
![A visual overview of an Unleash system as described in the following paragraph.](/img/unleash-architecture-edge.png 'System Overview')
A web interface for managing feature flags, defining activation strategies, viewing analytics, configuring access roles, generating API tokens, and more.
- [**Unleash API**](/reference/api/unleash) - The Unleash instance. This is where you create feature flags, configure activation strategies, and parameters, etc. The service that contains all feature flags and their configurations. Configurations declare which activation strategies to use and which parameters they should get.
- **Unleash Admin UI** - The bundled web interface for interacting with the Unleash instance. Manage flags, define strategies, look at metrics, and much more. Use the UI to [create feature flags](/how-to-create-feature-flag), [manage project access roles](../how-to/how-to-create-and-assign-custom-project-roles), [create API tokens](/reference/api-tokens-and-client-keys#create-an-api-token), and more.
- [**Unleash SDKs**](../reference/sdks) - Unleash SDKs integrate into your applications and get feature configurations from the Unleash API. Use them to check whether features are enabled or disabled and to send metrics to the Unleash API. [See all our SDKs](../reference/sdks)
- [**Unleash Edge**](../reference/unleash-edge) - The Unleash Edge sits between front-end and native applications on one side and the Unleash API on the other. It can also sit between server-side SDKs and the Unleash API as well. You can scale it independently of the Unleash API to handle large request rates without causing issues for the Unleash API. Edge has all endpoints for the client API, frontend API, and proxy API.
![A visual overview of an Unleash system as described in the following paragraph.](/img/unleash-admin-ui.png)
To be super fast (_we're talking nano-seconds_), the [client SDK](../reference/sdks) caches all feature flags and their current configuration in memory. The activation strategies are also implemented in the SDK. This makes it really fast to check if a flag is on or off because it is just a simple function operating on local state, without the need to poll data from the database.
### Unleash SDKs
Unleash provides both [server-side](/reference/sdks#server-side-sdks) and [client-side SDKs](/reference/sdks#client-side-sdks) for integrating feature flagging into your applications. SDKs fetch data from the Unleash API to check which feature flags are enabled. Server-side SDKs fetch all feature flag configuration data and perform the evaluation locally, while client-side SDKs fetch evaluated feature flags only.
#### Server-side SDKs
Server-side SDKs run in backend applications and retrieve feature flag configurations using the [Client API](#client-api) either from Unleash server or [Unleash Edge](#unleash-edge). Server-side SDKs cache all feature flag data in memory, applying activation strategies locally. This makes flag evaluation incredibly fast, as it is a simple function operating on local state, without the need to poll data from the database. This architecture results in a small delay (typically a few seconds, but configurable) when propagating configuration changes to your applications.
Supported languages include: [Node.js](/reference/sdks/node), [Go](/reference/sdks/go), [Java](/reference/sdks/java), [Python](/reference/sdks/python), [.NET](/reference/sdks/dotnet), [PHP](/reference/sdks/php), and more.
#### Client-side SDKs
Client-side SDKs are used in frontend and mobile applications. They communicate with Unleash or [Unleash Edge](#unleash-edge) through the [Frontend API](#frontend-api). Supported platforms include: [JavaScript](/reference/sdks/javascript-browser), [React](/reference/sdks/react), [iOS](/reference/sdks/ios-proxy), [Android](/reference/sdks/android-proxy), and more.
Unlike server-side SDKs, client-side SDKs do not perform the flag evaluation locally. Instead, they fetch all enabled feature flags for a given [Unleash Context](/reference/unleash-context). The flag evaluation happens inside [Unleash Edge](#unleash-edge), or within the Unleash server. Client-side SDKs cache evaluated feature flags in memory using a single evaluation call to the server, making flag evaluation secure, fast, and efficient.
### Flag evaluation
The following table outlines where flag evaluation happens with different SDK setups.
| SDK setup | Feature flag evaluation |
|------------------------------------|--------------------------------------------------|
| Server-side SDK + Unleash | Performed **locally** within the SDK. |
| Server-side SDK + Unleash Edge | Performed **locally** within the SDK. |
| Client-side SDK + Unleash | Performed by the **Unleash server**. |
| Client-side SDK + Unleash Edge | Performed by **Unleash Edge**. |
Flag evaluation relies on the [Unleash Context](/reference/unleash-context) and may involve user data. Since server-side SDKs always perform local evaluation, your user data remains within your application and is never shared with the Unleash server.
For client-side SDKs, you can use Unleash Edge for flag evaluation to ensure that user data is not shared with the Unleash server. You have different hosting options for both [Unleash](/understanding-unleash/proxy-hosting#you-host-everything) and [Unleash Edge](/understanding-unleash/proxy-hosting#unleash-hosts-the-api-you-host-edge) allowing you to meet any privacy requirements.
### Unleash Edge
Unleash Edge is a lightweight caching layer designed to improve scalability, performance, and resilience. It sits between your SDKs and the Unleash API and handles thousands of connected SDKs without increasing the number of requests you make to your Unleash instance.
Beyond scalability, Unleash Edge also offers privacy and security benefits for client-side SDKs by performing flag evaluations without exposing sensitive data to end-users or to Unleash.
### Unleash APIs
#### Client API
The [Client API](/reference/api/unleash/client) is the API used by server-side SDKs to fetch feature flag configurations and send SDK usage metrics to Unleash.
#### Frontend API
The [Frontend API](/reference/api/unleash/frontend-api) is the API used by client-side SDKs to retrieve all enabled feature flags for a given [Unleash Context](/reference/unleash-context) and send SDK usage metrics to Unleash.
#### Admin API
The [Admin API](/reference/api/unleash) is an API layer for managing all aspects of your Unleash instance, including creating, updating, and deleting resources, such as feature flags, activation strategies, and environments. This API is used by the [Unleash Admin UI](#the-unleash-admin-ui) and other tools and [integrations](/reference/integrations).
| API | Used by | Available endpoints |
|---------------|---------|---|
| Client API | Server-side SDKs | Get all enabled feature flags for a given context, register an SDK, send SDK usage metrics. |
| Frontend API | Client-side SDKs | Get a feature flag by name, get all feature flags, register an SDK, send SDK usage metrics. |
| Admin API | Admin UI, internal tooling, third-party integrations | Access and manage all resources within Unleash, such as context, environments, events, metrics, and users. |
## Get started with Unleash
To integrate Unleash, you first need an [Unleash server](#the-unleash-api). You can choose from:
- Unleash Enterprise:
- [Cloud-hosted plans](https://www.getunleash.io/pricing)
- [Self-hosted plans](https://www.getunleash.io/pricing)
- Open-source deployment options:
- [Docker](../using-unleash/deploy/getting-started)
- [Helm Chart](https://github.com/unleash/helm-charts/)
- [GitLab](https://docs.gitlab.com/ee/operations/feature_flags.html#choose-a-client-library)
For a deeper dive into Unleashs architecture, check out this [blog post](https://www.getunleash.io/blog/our-unique-architecture).

View File

@ -2,5 +2,5 @@
title: My requests are being blocked by CORS
---
1. Make sure you've configured CORS access in Unleash admin UI settings as defined in the [Unleash CORS Policy docs](/reference/front-end-api#cors). These settings can be changed in the Unleash Dashboard under **Settings -> CORS Origins** or by using the [API](/reference/api/unleash/set-ui-config). Allowing all origins (using a single asterisk) will address this matter and is a great starting point when troubleshooting the behavior.
1. Make sure you've configured CORS access in Unleash admin UI settings as defined in the [Unleash CORS Policy docs](/reference/front-end-api#configure-cross-origin-resource-sharing-cors). These settings can be changed in the Unleash Dashboard under **Settings -> CORS Origins** or by using the [API](/reference/api/unleash/set-ui-config). Allowing all origins (using a single asterisk) will address this matter and is a great starting point when troubleshooting the behavior.
1. When receiving "**No 'Access-Control-Policy' header is present on the requested resource**", using the command `curl -I https://<host>/<endpoint>` will allow us to verify that the response includes the header `Access-Control-Allow-Origin: *`.

Binary file not shown.

After

Width:  |  Height:  |  Size: 436 KiB