A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://docs.npmjs.com/creating-and-viewing-access-tokens below:

Creating and viewing access tokens

Creating and viewing access tokens

You can create and view access tokens from the website and command line interface (CLI).

Creating access tokens Creating legacy tokens on the website

Note: For greater security, we recommend using granular access tokens instead of legacy read-only tokens or legacy automation tokens.

  1. In the upper right corner of the page, click your profile picture, then click Access Tokens.

  2. Click Generate New Token, then select legacy token from the dropdown menu.

  3. (Optional) Name your token.

  4. Select the type of access token:

  5. Click Generate Token.

  6. Copy the token from the top of page.

Creating granular access tokens on the website
  1. In the upper right corner of the page, click your profile picture, then click Access Tokens.

  2. Click Generate New Token, then click Granular Access Token.

  3. In the Token name field, enter a name for your token.

  4. (Optional) In the Description field, enter a description for your token.

  5. In the Expiration field, enter a token expiration period. The date must be at least 1 day in the future.

  6. (Optional) In the Allowed IP Ranges field, enter IP address ranges to restrict your access token to. You must use CIDR notation to enter IP address ranges. To add more than one allowed IP range, click Add IP Range and enter an IP range in the new text field.

  7. (Optional) In the Packages and scopes section, configure your token's access to packages and scopes.

  8. (Optional) In the Organizations section, configure your token's access to organizations.

    Note: When you give a token access to an organization, the token can only be used for managing organization settings and teams or users associated with the organization. It does not give the token the right to publish packages managed by the organization.

  9. Review the token summary, then click Generate Token.

  10. Copy the token from the top of page.

Creating tokens with the CLI

You can create tokens with read-only permissions or read and publish permissions with the CLI.

Note: You cannot create legacy automation tokens or granular access tokens from the CLI. You must use the website to generate these types of tokens. For more information, see "Creating legacy tokens on the website" and "Creating granular access tokens on the website."

In addition, you can specify that the token is only valid for a specific IPv4 address range, using CIDR notation. The token will only be valid when used from the specified IP addresses.

  1. To create a new token, on the command line, run:
  2. When prompted, enter your password.
  3. If you have enabled two-factor authentication, when prompted, enter a one-time password.
  4. Copy the token from the token field in the command output.
CIDR-restricted token errors

If the CIDR string you enter is invalid or in an inappropriate format, you will get an error similar to the one below:

npm ERR! CIDR whitelist contains invalid CIDR entry: X.X.X.X./YY,Z.Z.. . .

Make sure you are using a valid IPv4 range and try creating the token again.

Viewing access tokens

Note: Full tokens are never displayed, only the first and last four characters will be shown. You can only view a full token immediately after creation.

Viewing tokens on the website

To view all tokens associated with your account, in the upper right corner of the page, click your profile picture, then click Access Tokens.

Viewing tokens on the CLI

To view all tokens associated with your account, on the command line, run the following command:

npm token list Token attributes

RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4