---
title: "Check Feature access"
description: "Check a customer\u2019s access or available balance without spending units."
api: POST https://i.nuxie.ai/entitled
authMethod: none
playground: simple
search:
  tags: ["api", "app", "reference"]
  keywords: ["entitled", "hasFeature", "Feature key", "requiredBalance", "allowed"]
---

Check whether a customer can use a published Feature. This request reads access without spending units. To charge for an action, [consume usage](/docs/api-reference/app/consume).

## Request body

- **`apiKey`** · body · `string` · required

  Publishable key for the app platform. A `pk_test_` key selects test data; a `pk_live_` key selects live data. Copy it from **Connect your app**.

- **`customerId`** · body · `string` · required

  The identified or anonymous customer ID your app supplies to the SDK, rather than Nuxie's internal customer record ID. See [Customer identifiers](/docs/api-reference/rest-api#customer-identifiers).

- **`featureId`** · body · `string` · required

  Published Feature key, such as `premium-export`. Several Products can grant the same Feature.

- **`requiredBalance`** · body · `integer`

  Units needed for the action. Accepts `1` to `9,007,199,254,740,991`; defaults to `1`.

- **`requiredQuantity`** · body · `integer`

  Alias for `requiredBalance`. If you send both, their values must match.

- **`entityId`** · body · `string`

  Identifier for entity-scoped access. Must be non-empty, trimmed, and at most 256 bytes.

Unknown request fields return `400`.

## Response

- **`customerId`** · `string` · required

  Customer identity supplied in the request.

- **`featureId`** · `string` · required

  Published Feature key that was checked.

- **`requiredBalance`** · `integer` · required

  Number of units checked.

- **`code`** · `string` · required

  Reason for the result. See the decision codes below.

- **`allowed`** · `boolean` · required

  Whether the customer has the requested access. A `200` response can have `allowed: false`.

- **`unlimited`** · `boolean` · required

  Whether usage is unlimited.

- **`balance`** · `number` · required

  Remaining units, or `null` for unlimited access.

- **`type`** · `string` · required

  Feature type: `boolean`, `metered`, or `creditSystem`.

For a Boolean Feature, `allowed` reports active access independently of the balance. For a metered Feature or credit system, access must be active and either unlimited or have enough units for `requiredBalance`. Unlimited access has a `null` balance.

`allowed: false` means the customer does not have the requested access, even when the HTTP status is `200`.

| `code` | Meaning |
| --- | --- |
| `feature_found` | The Feature was checked; read `allowed` for the decision |
| `customer_missing` | No customer record exists for the supplied ID |
| `feature_inapplicable` | The Feature does not apply to the platform making the request |
| `feature_not_found` | No published Feature matches; HTTP `404` |
| `billing_unavailable` | Access could not be checked; HTTP `503` |

```sh title="cURL"
curl https://i.nuxie.ai/entitled \
  --header 'Content-Type: application/json' \
  --data '{
  "apiKey": "pk_test_example",
  "customerId": "user-456",
  "featureId": "premium-export",
  "requiredBalance": 1
}'
```

```json title="200"
{
  "customerId": "user-456",
  "featureId": "premium-export",
  "requiredBalance": 1,
  "code": "feature_found",
  "allowed": true,
  "unlimited": false,
  "balance": 0,
  "type": "boolean"
}
```
