Skip to content

[BUG] npm token create no longer prints token #8684

@lucaswerkmeister

Description

@lucaswerkmeister

Is there an existing issue for this?

  • I have searched the existing issues

This issue exists in the latest npm version

  • I am using the latest npm

Current Behavior

npm token create no longer prints the token it creates. The token is still created (I can see it in my settings), but as the full token is never shown, it’s AFAICT completely useless.

npm token create command, with final output: Created publish token npm_***

Expected Behavior

According to the documentation, there should be a “token field in the command output.”

Steps To Reproduce

  1. Run npm token create
  2. Jump through the authentication hoops (password, auth link, 2FA, etc.)
  3. Inspect the output

Environment

  • npm: 11.6.2
  • Node.js: 20.19.5
  • OS Name: Arch Linux
  • System Model Name:
  • npm config:
; "user" config from /home/lucas/.npmrc

//registry.npmjs.org/:_authToken = (protected)

; node bin location = /usr/bin/node
; node version = v20.19.5
; npm local prefix = /home/lucas
; npm version = 11.6.2
; cwd = /home/lucas
; HOME = /home/lucas
; Run `npm config ls -l` to show all defaults.

Metadata

Metadata

Assignees

No one assigned

    Labels

    Bugthing that needs fixingNeeds Triageneeds review for next steps

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions