---
title: Intro to NerdStorageVault
source: https://docs.newrelic.com/docs/new-relic-solutions/build-nr-ui/nerdstoragevault
---

To help you build a New Relic application, we provide you with the [New Relic SDK](https://docs.newrelic.com/docs/new-relic-solutions/build-nr-ui/sdk-component/intro-to-sdk). On this page, you'll learn how to use `NerdStorageVault` to store data in an encrypted storage solution.

## Using `NerdStorageVault` in your apps [#using]

Use `NerdStorageVault` to store and retrieve sensitive secrets data such as:

-   personal access tokens
-   license keys
-   API keys
-   other third party secrets

> #### 💡 TIP
>
> `NerdStorageVault` is encrypted with AES-256 encryption.

## Usage considerations [#usage]

-   This storage is unique per Nerdpack, and can't be shared with any other Nerdpack.
-   `NerdStorageVault` can currently only be used within the context of a Nerdpack.
-   You cannot make a direct query or mutation to `NerdStorageVault`.
-   You can explore the fields and response types via the [NerdGraph API explorer](https://api.newrelic.com/graphiql).
-   The only supported scope is ACTOR, or data that relates to a particular user.

## Component library [#component]

Currently `NerdStorageVault` is available in the alpha release of [Nr1 Community component library](https://www.npmjs.com/package/@newrelic/nr1-community/v/1.3.0-alpha.5) and is not available in the Nr1 core components library. Open source components can be use to augment Nr1 core components for additional functionality.

## NerdGraph queries [#nerdgraph]

Below are examples of the queries used by the components to interact with `NerdStorageVault`.

> #### 💡 TIP
>
> `NerdStorageVault` can currently only be used within the context of a Nerdpack.

### Write [#write]

```graphql
mutation {
  nerdStorageVaultWriteSecret(
    scope: { actor: CURRENT_USER }
    secret: { key: "test", value: "secret_test" }
  ) {
    status
    errors {
      message
      type
    }
  }
}
```

### Delete [#delete]

```graphql
mutation {
  nerdStorageVaultDeleteSecret(
    scope: { actor: CURRENT_USER }
    key: "test_key"
  ) {
    status
    errors {
      message
      type
    }
  }
}
```

### Fetch a single secret [#fetch-single]

```graphql
query {
  actor {
    nerdStorageVault {
      secret(key: "test_key") {
        key
        value
      }
    }
  }
}
```

### Fetch a list of secrets [#fetch-list]

```graphql
query {
  actor {
    nerdStorageVault {
      secrets {
        key
        value
      }
    }
  }
}
```

### Limits [#limits]

-   A secret value is limited to 5000 characters.
-   A key value is limited to 64 characters.
-   A key value must only include alphanumeric, '\_' or '-' characters

### Permissions for working with `NerdStorageVault` [#permissions]

In order to persist changes to `NerdStorageVault`, such as writing, deleting,
and fetching data, you must have a [user role with permission to persist changes](https://docs.newrelic.com/docs/accounts/original-accounts-billing/original-users-roles/users-roles-original-user-model).
