Skip to content

Commit 5c96653

Browse files
ochafikclaude
andauthored
release: 0.0.3, switched to npm trusted publishing (#101)
* version: 0.0.2 * Switch to npm trusted publishing (OIDC) - Remove NPM_TOKEN secret requirement from npm-publish workflow - Uses OIDC for authentication (more secure, no long-lived tokens) - Update CONTRIBUTING.md with trusted publisher setup instructions 🤖 Generated with [Claude Code](https://claude.com/claude-code) Co-Authored-By: Claude <[email protected]> * 0.0.3 --------- Co-authored-by: Claude <[email protected]>
1 parent fd29038 commit 5c96653

File tree

4 files changed

+19
-14
lines changed

4 files changed

+19
-14
lines changed

.github/workflows/npm-publish.yml

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,7 +45,7 @@ jobs:
4545
publish:
4646
runs-on: ubuntu-latest
4747
if: github.event_name == 'release'
48-
environment: release
48+
environment: Release
4949
needs: [build, test]
5050

5151
permissions:
@@ -80,6 +80,6 @@ jobs:
8080
echo "tag=" >> $GITHUB_OUTPUT
8181
fi
8282
83+
# Uses OIDC trusted publishing - no NPM_TOKEN needed
84+
# Configure at: https://www.npmjs.com/package/@modelcontextprotocol/ext-apps/access
8385
- run: npm publish --provenance --access public ${{ steps.npm-tag.outputs.tag }}
84-
env:
85-
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}

CONTRIBUTING.md

Lines changed: 13 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -60,16 +60,21 @@ Please review our [Security Policy](SECURITY.md) for reporting security vulnerab
6060

6161
### Repository Setup
6262

63-
Before publishing releases, ensure the following are configured:
63+
This repository uses [npm trusted publishing](https://docs.npmjs.com/trusted-publishers/) with OIDC - no secrets required.
6464

65-
1. **NPM_TOKEN secret**: Add an npm automation token to the repository secrets
66-
- Go to Settings � Secrets and variables � Actions
67-
- Create a new secret named `NPM_TOKEN`
68-
- Value: an npm automation token with publish permissions for `@modelcontextprotocol/ext-apps`
65+
Before publishing releases, ensure the following are configured:
6966

70-
2. **`release` environment** (optional): Create a protected environment for additional safeguards
71-
- Go to Settings � Environments � New environment
72-
- Name it `release`
67+
1. **Trusted publisher on npm**: Configure the package to trust this GitHub repository
68+
- Go to https://www.npmjs.com/package/@modelcontextprotocol/ext-apps/access
69+
- Under "Trusted Publishers", click "Add trusted publisher"
70+
- Select "GitHub Actions"
71+
- Repository: `modelcontextprotocol/ext-apps`
72+
- Workflow filename: `npm-publish.yml`
73+
- Environment: `Release` (optional, for additional protection)
74+
75+
2. **`Release` environment** (optional): Create a protected environment for additional safeguards
76+
- Go to Settings > Environments > New environment
77+
- Name it `Release`
7378
- Add required reviewers or other protection rules as needed
7479

7580
### Publishing a Release

package-lock.json

Lines changed: 2 additions & 2 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

package.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
{
22
"homepage": "https://github.com/modelcontextprotocol/ext-apps",
33
"name": "@modelcontextprotocol/ext-apps",
4-
"version": "0.0.2",
4+
"version": "0.0.3",
55
"license": "MIT",
66
"description": "MCP Apps SDK — Enable MCP servers to display interactive user interfaces in conversational clients.",
77
"type": "module",

0 commit comments

Comments
 (0)