Skip to content

feat: add npm trusted publishing with OIDC authentication#244

Merged
ls-ramos merged 4 commits intomainfrom
feature/122288-trusted-publisher
Feb 9, 2026
Merged

feat: add npm trusted publishing with OIDC authentication#244
ls-ramos merged 4 commits intomainfrom
feature/122288-trusted-publisher

Conversation

@ls-ramos
Copy link
Copy Markdown
Contributor

@ls-ramos ls-ramos commented Feb 2, 2026

Success criteria

  • Packages can be published to npm using OIDC authentication (trusted publishing)
  • No long-lived npm tokens are required in GitHub secrets
  • Provenance attestations are automatically generated for published packages

How to test

  1. Configure trusted publisher on npmjs.com for this package:
    • Organization: Cognigy
    • Repository: Webchat
    • Workflow filename: publish.yml
  2. Merge this PR and create a release
  3. Verify the package is published successfully without npm_token

Security

  • Possible injection vector
  • Authentication/Access controls touched
  • Sensitive Data could be exposed
  • XSS
  • Logging/Monitoring touched
  • Exchanges data with external systems
  • No security implications

Additional considerations

  • This PR might have performance implications

Documentation Considerations

These are hints for the documentation team to help write the docs.

Copilot AI review requested due to automatic review settings February 2, 2026 17:00
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR migrates the npm publishing workflow from using long-lived authentication tokens to OIDC-based trusted publishing, eliminating the need to store npm credentials in GitHub secrets while automatically generating provenance attestations.

Changes:

  • Implements OIDC authentication for npm trusted publishing with required permissions
  • Removes manual .npmrc configuration and npm token handling
  • Updates Node.js version from 22.x to 24.x

Comment thread .github/workflows/publish.yml
@graymalkin77
Copy link
Copy Markdown

graymalkin77 commented Feb 2, 2026

Snyk checks have passed. No issues have been found so far.

Status Scanner Critical High Medium Low Total (0)
Open Source Security 0 0 0 0 0 issues
Licenses 0 0 0 0 0 issues
Code Security 0 0 0 0 0 issues

💻 Catch issues earlier using the plugins for VS Code, JetBrains IDEs, Visual Studio, and Eclipse.

@ls-ramos ls-ramos requested a review from a team February 9, 2026 11:36
Copilot AI review requested due to automatic review settings February 9, 2026 11:42
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Copilot reviewed 6 out of 7 changed files in this pull request and generated 2 comments.

Comment thread .github/workflows/release.yml Outdated
Comment thread .github/workflows/format.yml Outdated
@ls-ramos ls-ramos merged commit 9d70f7e into main Feb 9, 2026
7 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants