> ## Documentation Index
> Fetch the complete documentation index at: https://docs.talosjs.com/llms.txt
> Use this file to discover all available pages before exploring further.

# npm:credentials:create

> Save an npm Granular Access Token under the user config.

Save an npm Granular Access Token so [`npm:publish`](/cli/commands/npm-publish) can authenticate with the registry. The token is written as block-style YAML to `~/.talos/credentials/npm.yml` under the `default` profile.

Create a Granular Access Token at [npmjs.com](https://www.npmjs.com/settings/~/tokens/granular-access-tokens/new).

## Usage

```bash theme={null}
talos npm:credentials:create [options]
```

## Examples

Run with no flags to be prompted for the token (input is hidden):

```bash theme={null}
talos npm:credentials:create
```

Provide the token non-interactively:

```bash theme={null}
talos npm:credentials:create --token=npm_xxxxxxxxxxxxxxxx
```

## Options

| Option     | Description                                                       | Default             |
| ---------- | ----------------------------------------------------------------- | ------------------- |
| `--token`  | npm Granular Access Token to store.                               | Prompted if omitted |
| `--silent` | Suppress the instructional message and the saved-to confirmation. | `false`             |
