diff --git a/nodejs/vercel-sdk/sample-agent/package.json b/nodejs/vercel-sdk/sample-agent/package.json index 692894d6..525d6330 100644 --- a/nodejs/vercel-sdk/sample-agent/package.json +++ b/nodejs/vercel-sdk/sample-agent/package.json @@ -3,6 +3,7 @@ "version": "2025.11.6", "description": "Sample agent integrating Vercel AI SDK Agents with Microsoft 365 Agents SDK and Microsoft Agent 365 SDK", "main": "src/index.ts", + "type": "commonjs", "scripts": { "start": "node dist/index.js", "dev": "nodemon --watch src/*.ts --exec ts-node src/index.ts", diff --git a/nodejs/vercel-sdk/sample-agent/src/index.ts b/nodejs/vercel-sdk/sample-agent/src/index.ts index 85bd9eff..e3db4218 100644 --- a/nodejs/vercel-sdk/sample-agent/src/index.ts +++ b/nodejs/vercel-sdk/sample-agent/src/index.ts @@ -3,11 +3,11 @@ import { configDotenv } from 'dotenv'; configDotenv(); -import { AuthConfiguration, authorizeJWT, CloudAdapter, Request } from '@microsoft/agents-hosting'; +import { AuthConfiguration, authorizeJWT, CloudAdapter, loadAuthConfigFromEnv, Request } from '@microsoft/agents-hosting'; import express, { Response } from 'express' import { agentApplication } from './agent'; -const authConfig: AuthConfiguration = {}; +const authConfig: AuthConfiguration = loadAuthConfigFromEnv(); const server = express() server.use(express.json())