npm error 404 Not Found - PUT https://registry.npmjs.org/<package>npm error code E404
npm error 404 Not Found - PUT https://registry.npmjs.org/my-package - Not found
The package exists, so why “Not found”? npm answers 404 instead of 401/403 when the publish isn’t authorised. Common causes:
.yml; for reusable workflows, the caller’s file)environment:; it must matchid-token: write on the publishing job, or npm older than 11.5.1. With these, npm falls back to whatever token is configured.npx go-tokenless
It lists the missing pieces in your workflows and prints the exact npm trust github … command for each package, including --env when your job uses an environment.