---
updatedAt: 2026-09-25T19:31:33.000Z
agentTools:
  projectIndex: https://docs.atono.io/llms.txt
---

# Get started with the Atono SDK

Set up the SDK and confirm it's working in your application.

The Atono SDK connects your application to Atono so you can evaluate feature flags and track feature usage. Available capabilities depend on the SDK you use.

This guide shows the fastest path to a working setup. For full coverage of either topic, see [Feature flags](https://docs.atono.io/docs/sdk-feature-flags) and [Feature engagement](https://docs.atono.io/docs/sdk-feature-engagement).

# Choose an SDK

Choose the SDK based on your application type and the capabilities you need.

| SDK                                                                                 | Application type | Use it for                                         | Supports                        |
| ----------------------------------------------------------------------------------- | ---------------- | -------------------------------------------------- | ------------------------------- |
| [Web SDK](https://docs.atono.io/docs/get-started-with-the-atono-sdk#web-sdk)        | Client-side      | Browser-based JavaScript applications              | Feature flags and feature usage |
| [React SDK](https://docs.atono.io/docs/get-started-with-the-atono-sdk#react-sdk)    | Client-side      | React applications                                 | Feature flags and feature usage |
| [Java SDK](https://docs.atono.io/docs/get-started-with-the-atono-sdk#java-sdk)      | Server-side      | Java backend applications                          | Feature flags and feature usage |
| [Node.js SDK](https://docs.atono.io/docs/get-started-with-the-atono-sdk#nodejs-sdk) | Server-side      | Server-side JavaScript and TypeScript applications | Feature flags and feature usage |

<Callout icon="📘" theme="info">
  ### Client-side and server-side SDKs

  The Web and React SDKs run in the user’s browser and typically maintain context for the current user.

  The Node.js and Java SDKs run on your application server, which may handle requests for many users or customers. When a feature flag or usage event depends on customer or location, provide context for the current request.
</Callout>

<br />

***

# Prerequisites

You'll need an environment key from Atono. You can find your environment keys on the [Environments](https://docs.atono.io/docs/manage-environments#access-the-environments-page) page.

<br />

***

# Web SDK

Use the Web SDK for browser-based JavaScript applications. It supports feature flags and feature usage tracking.

## 1. Install the SDK

Run the following command in your project directory:

```shell Terminal
npm install --save @atono-io/web-sdk
```

## 2. Initialize the SDK

Connect the SDK to your Atono environment using your environment key. Initialize it once when your application starts:

```javascript JavaScript
import { Atono } from '@atono-io/web-sdk';

const atono = Atono.fromEnvironmentKey('$ENV_KEY');
```

Replace `$ENV_KEY` with your Atono environment key.

## 3. Evaluate a feature flag

Get the feature flag client and use the feature flag’s name to evaluate it:

```javascript
const featureFlags = await atono.getFeatureFlags();

if (featureFlags.getBooleanValue('flag_name', false)) {
    // Turn on the feature
}
```

Replace `flag_name` with your feature flag’s name in Atono.

The second argument, `false`, is the fallback value returned if the SDK can’t determine a value for the flag, such as when the flag doesn’t exist or no configuration has been retrieved.

For more information, see [Fallback value](https://docs.atono.io/docs/sdk-feature-flags#fallback-value).

## 4. Record feature usage

> Usage tracking requires version 1.1.0 or later of the Web SDK.

Call `record()` on the usage reporter when someone uses the feature you want to track. Pass the ID of the story associated with the feature, such as `STORY-67`.

In this example, `button` represents a reference to a specific element in the application. When that element is clicked, `record()` records a usage event for `STORY-67`.

```javascript
const usage = atono.getUsageReporter();

button.addEventListener('click', () => {
    usage.record('STORY-67');
});
```

Replace `STORY-67` with the ID of the story associated with the feature.

Usage events are published asynchronously, so calling `record()` doesn’t block while the SDK communicates with Atono.

Usage events appear in the story’s feature engagement graph. For more information, see [Feature engagement](https://docs.atono.io/docs/sdk-feature-engagement).

<br />

***

# React SDK

Use the React SDK for client-side React applications. It supports feature flags and feature usage tracking.

## 1. Install the SDK

Run the following command in your project directory:

```shell Terminal
npm install --save @atono-io/react-sdk
```

## 2. Initialize the SDK

Wrap your application in `<AtonoProvider>` and provide your environment key:

```jsx React
import { AtonoProvider } from '@atono-io/react-sdk';

function RootComponent() {
  return (
    <AtonoProvider environmentKey="$ENV_KEY">
      <App />
    </AtonoProvider>
  );
}
```

Replace `$ENV_KEY` with your Atono environment key.

Add the provider at the top level of your application so feature flags and usage tracking are available to the components inside it.

## 3. Evaluate a feature flag

Use the `useFeatureFlag()` hook in a component inside `<AtonoProvider>`:

```jsx React
import { useFeatureFlag } from '@atono-io/react-sdk';

function ChildComponent() {
    const isEnabled = useFeatureFlag()
        .getBooleanValue('flag_name', false);

    return isEnabled
        ? <Enabled />
        : <Disabled />;
}
```

Replace `flag_name` with your feature flag’s name in Atono.

The second argument, `false`, is the fallback value returned if the SDK can’t determine a value for the flag, such as when the flag doesn’t exist or no configuration has been retrieved. For more information, see [Fallback value](https://docs.atono.io/docs/sdk-feature-flags#fallback-value).

## 4. Record feature usage

> Usage tracking requires version 1.1.0 or later of the React SDK.

Use the `useUsageReporter()` hook and call `record()` when someone uses the feature.

In this example, the code creates a button labeled **Try the feature**. When a user clicks it, `onClick` calls `record()` to record a usage event for `STORY-67`.

```jsx React
import { useUsageReporter } from '@atono-io/react-sdk';

function TryButton() {
  const { record } = useUsageReporter();

  return (
    <button onClick={() => record('STORY-67')}>
      Try the feature
    </button>
  );
}
```

Pass the ID of the story associated with the feature, such as `STORY-67` .

Usage events appear in the story’s feature engagement graph. For more information, see [Feature engagement](https://docs.atono.io/docs/sdk-feature-engagement).

<br />

***

# Java SDK

Use the Java SDK for server-side Java applications. It supports feature flags and feature usage tracking.

## 1. Install the SDK

Add the Atono Java SDK as a dependency in your project.

<Callout icon="📘" theme="info">
  Replace `VERSION` in the Maven or Gradle example with the latest version available in <Anchor target="_blank" href="https://central.sonatype.com/artifact/io.atono/atono-java-sdk">Maven Central</Anchor>.
</Callout>

```xml Maven
<dependency>
    <groupId>io.atono</groupId>
    <artifactId>atono-java-sdk</artifactId>
    <version>VERSION</version>
</dependency>
```
```groovy Gradle
repositories {
    mavenCentral()
}

dependencies {
    implementation 'io.atono:atono-java-sdk:VERSION'
}
```

## 2. Initialize the SDK

Create an `Atono` client using your environment key. Configure it once when your application starts:

```java Java
import io.atono.sdk.Atono;

private static final Atono atono = Atono.builder().build("$ENV_KEY");
```

Replace `$ENV_KEY` with your Atono environment key.

## 3. Evaluate a feature flag

Use the feature flag’s name to evaluate it:

```java Java
if (atono.getFeatureFlags().getBooleanValue(
    "flag_name",
    false
)) {
    // This code executes when the feature is enabled.
}
```

Replace `flag_name` with your feature flag’s name in Atono.

The second argument, `false`, is the fallback value returned if the SDK can’t determine a value for the flag, such as when the flag doesn’t exist or no configuration has been retrieved. For more information, see [Fallback value](https://docs.atono.io/docs/sdk-feature-flags#fallback-value).

If the flag is configured by customer or location, include evaluation context when evaluating it. For more information, see [Set evaluation context](https://docs.atono.io/docs/sdk-feature-flags#set-evaluation-context).

## 4. Record feature usage

Call `record()` on the usage reporter when someone uses the feature you want to track. The usage key identifies the story associated with the feature, such as `STORY-67`.

```java Java
atono.getUsageReporter().record("STORY-67");
```

Replace `STORY-67` with the ID of the story associated with the feature.

Usage events are published asynchronously, so calling `record()` doesn’t block while the SDK communicates with Atono.

Usage events appear in the story’s feature engagement graph. For more information, see [Feature engagement](https://docs.atono.io/docs/sdk-feature-engagement).

If you want to associate a customer or location with the usage event, pass evaluation context with the `record()` call. For more information, see [Provide customer and location context](https://docs.atono.io/docs/sdk-feature-engagement#provide-customer-and-location-context).

<br />

***

# Node.js SDK

Use the Node.js SDK for server-side JavaScript and TypeScript applications. It supports feature flags and feature usage tracking.

## 1. Install the SDK

Run the following command in your project directory:

```shell Terminal
npm install --save @atono-io/server-sdk
```

## 2. Initialize the SDK

Connect the SDK to your Atono environment using your environment key. Initialize it once when your application starts:

```javascript JavaScript
const { Atono } = require('@atono-io/server-sdk');

const atono = Atono.fromEnvironmentKey('$ENV_KEY');
```

Replace `$ENV_KEY` with your Atono environment key.

## 3. Evaluate a feature flag

Get the feature flag client and use the feature flag’s name to evaluate it:

```javascript JavaScript
const featureFlags = await atono.getFeatureFlags();

const isEnabled = featureFlags.getBooleanValue(
    'flag_name',
    false,
    evaluationContext
);

if (isEnabled) {
    // Turn on the feature
}
```

Replace `flag_name` with your feature flag’s name in Atono.

The second argument, `false`, is the fallback value returned if the SDK can't determine a value for the flag, such as when the flag doesn't exist or no configuration has been retrieved. For more information, see [Fallback value](https://docs.atono.io/docs/sdk-feature-flags#fallback-value).

The third argument, `evaluationContext`, provides the customer and location for the current request. Because the Node.js SDK runs on your server, pass context with each evaluation when the flag is configured by customer or location. For more information, see [Set evaluation context](https://docs.atono.io/docs/sdk-feature-flags#set-evaluation-context).

## 4. Record feature usage

Call `record()` on the usage reporter when someone uses the feature you want to track. Pass the ID of the story associated with the feature, such as `STORY-67`.

```javascript JavaScript
const usage = atono.getUsageReporter();

usage.record('STORY-67');
```

Replace `STORY-67` with the ID of the story associated with the feature.

Usage events are published asynchronously, so calling `record()` doesn’t block while the SDK communicates with Atono.

Usage events appear in the story’s feature engagement graph. For more information, see [Feature engagement](https://docs.atono.io/docs/sdk-feature-engagement).

If you want to associate a customer or location with the usage event, pass evaluation context with the `record()` call. For more information, see [Provide customer and location context](https://docs.atono.io/docs/sdk-feature-engagement#provide-customer-and-location-context).

<br />