Skip to content

Commit 28ee388

Browse files
authored
Merge pull request #2 from 3nethz/main
Refactor Action secrets and update name to AsgardeoMcpAuth
2 parents fd2bc68 + 9e79f47 commit 28ee388

File tree

8 files changed

+23
-17
lines changed

8 files changed

+23
-17
lines changed

.changeset/config.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"changelog": [
66
"@changesets/changelog-github",
77
{
8-
"repo": "asgardeo/mcp-node"
8+
"repo": "asgardeo/asgardeo-mcp-node"
99
}
1010
],
1111
"commit": false,

.changeset/petite-peaches-tie.md

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,6 @@
1+
---
2+
'@asgardeo/mcp-express': patch
3+
'@asgardeo/mcp-node': patch
4+
---
5+
6+
Renamed all occurrences of `McpAuthServer` to `AsgardeoMcpAuth` across all relevant source files.

.github/workflows/release.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,7 +11,7 @@ on:
1111
concurrency: ${{ github.workflow }}-${{ github.ref }}
1212

1313
env:
14-
GH_TOKEN: ${{ secrets.RELEASE_BOT_TOKEN }}
14+
GH_TOKEN: ${{ secrets.ASGARDEO_GITHUB_BOT_TOKEN }}
1515
NPM_TOKEN: ${{ secrets.NPM_TOKEN }}
1616

1717
jobs:

examples/express-mcp-server/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
import express from 'express';
22
import {config} from 'dotenv';
3-
import {McpAuthServer, protectedRoute} from '@asgardeo/mcp-express';
3+
import {AsgardeoMcpAuth, protectedRoute} from '@asgardeo/mcp-express';
44
import {protectedRoutes} from './routes/protected';
55
import {publicRoutes} from './routes/public';
66

@@ -12,7 +12,7 @@ const port = process.env.PORT || 3000;
1212
app.use(express.json());
1313

1414
app.use(
15-
McpAuthServer({
15+
AsgardeoMcpAuth({
1616
baseUrl: process.env.BASE_URL as string,
1717
}),
1818
);

examples/express-mcp-vet-ai-assist-app/src/index.ts

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
*/
1818

1919
import {randomUUID} from 'node:crypto';
20-
import {McpAuthServer, protectedRoute} from '@asgardeo/mcp-express';
20+
import {AsgardeoMcpAuth, protectedRoute} from '@asgardeo/mcp-express';
2121
import {McpServer} from '@modelcontextprotocol/sdk/server/mcp';
2222
import {StreamableHTTPServerTransport} from '@modelcontextprotocol/sdk/server/streamableHttp';
2323
import {isInitializeRequest} from '@modelcontextprotocol/sdk/types';
@@ -30,7 +30,7 @@ config();
3030
const app: Express = express();
3131
app.use(express.json());
3232
app.use(
33-
McpAuthServer({
33+
AsgardeoMcpAuth({
3434
baseUrl: process.env.BASE_URL as string,
3535
}),
3636
);

package.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -23,7 +23,8 @@
2323
"fix:lint": "nx run-many --target=fix:lint --all --parallel",
2424
"lint": "nx run-many --target=lint --all --parallel",
2525
"publish:packages": "changeset publish",
26-
"version:packages": "changeset version && pnpm install --lockfile-only"
26+
"version:packages": "changeset version && pnpm install --lockfile-only",
27+
"test": "echo \"No tests configured\""
2728
},
2829
"devDependencies": {
2930
"@changesets/changelog-github": "^0.5.1",
@@ -41,6 +42,5 @@
4142
"workspaces": [
4243
"packages/*",
4344
"examples/*"
44-
],
45-
"packageManager": "[email protected]+sha512.0e82714d1b5b43c74610193cb20734897c1d00de89d0e18420aebc5977fa13d780a9cb05734624e81ebd81cc876cd464794850641c48b9544326b5622ca29971"
45+
]
4646
}

packages/mcp-express/README.md

Lines changed: 7 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -36,13 +36,13 @@ pnpm add @asgardeo/mcp-express
3636

3737
```typescript
3838
import express from 'express';
39-
import {McpAuthServer, protectedRoute} from '@asgardeo/mcp-express';
39+
import {AsgardeoMcpAuth, protectedRoute} from '@asgardeo/mcp-express';
4040

4141
const app = express();
4242

4343
// Initialize MCP authentication server with baseUrl
4444
app.use(
45-
McpAuthServer({
45+
AsgardeoMcpAuth({
4646
baseUrl: process.env.BASE_URL as string,
4747
}),
4848
);
@@ -60,14 +60,14 @@ app.use('/api/protected', protectedRoute, (req, res) => {
6060

6161
### API Reference
6262

63-
#### McpAuthServer(options)
63+
#### AsgardeoMcpAuth(options)
6464

6565
Initializes the MCP authentication server middleware with the given configuration.
6666

6767
```typescript
68-
import {McpAuthServer} from '@asgardeo/mcp-express';
68+
import {AsgardeoMcpAuth} from '@asgardeo/mcp-express';
6969

70-
app.use(McpAuthServer({baseUrl: 'https://auth.example.com'}));
70+
app.use(AsgardeoMcpAuth({baseUrl: 'https://auth.example.com'}));
7171
```
7272

7373
#### protectedRoute
@@ -97,15 +97,15 @@ Here's a complete example of setting up an Express server with MCP authenticatio
9797

9898
```typescript
9999
import express from 'express';
100-
import {McpAuthServer, protectedRoute} from '@asgardeo/mcp-express';
100+
import {AsgardeoMcpAuth, protectedRoute} from '@asgardeo/mcp-express';
101101

102102
const app = express();
103103
const port = process.env.PORT || 3000;
104104

105105
app.use(express.json());
106106

107107
// Initialize MCP authentication
108-
app.use(McpAuthServer());
108+
app.use(AsgardeoMcpAuth());
109109

110110
// Public routes
111111
app.use('/api', publicRoutes);

packages/mcp-express/src/public-api.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,5 +16,5 @@
1616
* under the License.
1717
*/
1818

19-
export {default as McpAuthServer} from './routes/auth';
19+
export {default as AsgardeoMcpAuth} from './routes/auth';
2020
export {default as protectedRoute} from './middlewares/protected-route';

0 commit comments

Comments
 (0)