Repository navigation
Add career-coach scenario: Career Coach autopilot using Node.js SDK #338
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Open
Akshit-MSFT (Akshit0022)
wants to merge
13
commits into
microsoft:main
Choose a base branch
from
Akshit0022:scenario/career-coach
base: main
Could not load branches
Branch not found: {{ refName }}
Loading
Could not load tags
Nothing to show
Loading
Are you sure you want to change the base?
Some commits from the old base branch may be removed from the timeline,
and old review comments may become outdated.
+11,068
−0
Open
Changes from all commits
Commits
Show all changes
13 commits
Select commit
Hold shift + click to select a range
bd4e262
Add career-coach scenario: Career Coach autopilot using Node.js SDK
Akshit0022 e27d31d
Merge branch 'main' of microsoft/Agent365-Samples into scenario/caree…
Akshit0022 fc93651
Update career-coach: S2S observability, email channel, goal lifecycle…
Akshit0022 52223e5
Address Copilot review round on fc93651 (authz, concurrency, subscrip…
Akshit0022 f35c140
Merge branch 'main' of microsoft/Agent365-Samples into scenario/caree…
Akshit0022 e8f6d35
Bump @azure/msal-node to ^7.1.1 (GHSA-xcx6-jx8p-x3h5)
Akshit0022 f797f7a
Merge branch 'main' of microsoft/Agent365-Samples into scenario/caree…
Akshit0022 c773016
career-coach: address round-3 review (22 threads)
Akshit0022 def7eae
career-coach: address round-4 review (13 threads)
Akshit0022 3ef0109
career-coach: address round-5 review (7 threads)
Akshit0022 5f6388f
address round-6 review (4 threads)
Akshit0022 9e1782e
fix round-7 PR review comments
Akshit0022 efbef0f
fix round-8 PR review comments
Akshit0022 File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Some comments aren't visible on the classic Files Changed page.
There are no files selected for viewing
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,148 @@ | ||
| # ───────────────────────────────────────────────────────────────────────────── | ||
| # Career Coach autopilot — environment template | ||
| # Copy this file to .env and fill in the values marked <CHANGE_ME>. | ||
| # All non-secret defaults are kept — you can leave those as-is. | ||
| # Never commit the filled-in .env. | ||
| # ───────────────────────────────────────────────────────────────────────────── | ||
|
|
||
| # ============================================================================= | ||
| # 1. OPENAI CONFIGURATION | ||
| # ============================================================================= | ||
| # Use EITHER standard OpenAI OR Azure OpenAI (not both). Azure OpenAI takes | ||
| # precedence if AZURE_OPENAI_API_KEY is set. | ||
|
|
||
| # --- Option A: Standard OpenAI --- | ||
| OPENAI_API_KEY= | ||
| OPENAI_MODEL=gpt-4o | ||
|
|
||
| # --- Option B: Azure OpenAI (recommended for this project) --- | ||
| # Uncomment and fill these three values to use Azure OpenAI. Leave them empty for Option A. | ||
| # AZURE_OPENAI_API_KEY=<your Azure OpenAI key> | ||
| # AZURE_OPENAI_ENDPOINT=https://<resource_name>.openai.azure.com/ | ||
| # AZURE_OPENAI_DEPLOYMENT=<your GPT-4o deployment name> | ||
| AZURE_OPENAI_API_KEY= | ||
| AZURE_OPENAI_ENDPOINT= | ||
| AZURE_OPENAI_DEPLOYMENT= | ||
| AZURE_OPENAI_API_VERSION=2024-10-21 | ||
|
|
||
|
|
||
| # ============================================================================= | ||
| # 2. MCP + OBSERVABILITY | ||
| # ============================================================================= | ||
| # Optional, local development only: a token for the MCP tool servers, from `a365 develop get-token`. | ||
| # Leave empty in deployed environments — the agent mints its own tokens per turn. | ||
| BEARER_TOKEN= | ||
|
|
||
| # A365 observability exporter. Export is opt-in: only the exact value "true" sends spans (which include | ||
| # the user's messages) to Agent 365. Ships "false" so a copied template exports nothing; set it to true | ||
| # once the agent is registered and you want Defender / Purview / admin-center reporting. | ||
| ENABLE_A365_OBSERVABILITY_EXPORTER=false | ||
|
|
||
| # Exporter diagnostics: none | info | warn | error (pipe-separated). warn|error surfaces failed exports; | ||
| # add info to also log successful export / token activity (useful while verifying telemetry, noisy afterwards). | ||
| A365_OBSERVABILITY_LOG_LEVEL=info|warn|error | ||
| # OpenTelemetry SDK diagnostics. Uncomment together with the line above to see export results. | ||
| # OTEL_LOG_LEVEL=INFO | ||
|
|
||
|
|
||
| # ============================================================================= | ||
| # 3. ENVIRONMENT SETTINGS | ||
| # ============================================================================= | ||
| # NODE_ENV=development | ||
| # HOST=127.0.0.1 | ||
| # PORT defaults to 3978. | ||
| # PORT=3978 | ||
|
|
||
| # Debug namespace. Narrowed from 'agents:*' to cut MSAL/connector noise while | ||
| # keeping onTurnError + adapter events visible. | ||
| DEBUG=agents:app:*,agents:cloud-adapter:* | ||
|
|
||
|
|
||
| # ============================================================================= | ||
| # 4. SHAREPOINT CONFIGURATION | ||
| # ============================================================================= | ||
| SP_SITE_HOST=<CHANGE_ME_tenant>.sharepoint.com | ||
| SP_SITE_PATH=/sites/CareerCoach | ||
| SP_LIST_COMPETENCY_FRAMEWORK=CompetencyFramework_v2 | ||
| SP_LIST_LEARNING_CATALOG=LearningCatalog_v2 | ||
| SP_LIST_USER_STATE=UserState | ||
| SP_LIST_LEARNING_PORTAL_STATUS=LearningPortalStatus | ||
| SP_LIST_QUIZ_RESPONSES=QuizResponses | ||
|
|
||
|
|
||
| # ============================================================================= | ||
| # 5. FEATURE 1 — REAL-TIME WEBHOOK (Graph subscription → proactive DM) | ||
| # ============================================================================= | ||
| # Random shared secret (at least 16 characters; empty or placeholder values are rejected). It is the | ||
| # Graph subscription clientState AND the X-Portal-Secret header for manual tests, and /api/portal-event | ||
| # sits in front of the JWT check, so treat it as a real secret. Generate one with: | ||
| # [Guid]::NewGuid().ToString() + [Guid]::NewGuid().ToString() | ||
| PORTAL_EVENT_SECRET= | ||
|
|
||
| # Public HTTPS URL that Microsoft Graph POSTs change notifications to. | ||
| # Point at your dev tunnel + /api/portal-event. Example: | ||
| # https://spiffy-dog-abc.inc1.devtunnels.ms/api/portal-event | ||
| # With NODE_ENV=production this needs a valid PORTAL_EVENT_SECRET and the service connection below, | ||
| # or the agent refuses to start. | ||
| PORTAL_WEBHOOK_URL=https://<CHANGE_ME_devtunnel>.inc1.devtunnels.ms/api/portal-event | ||
|
|
||
| # Optional: the agent's own ids, so the background Graph subscription can start before anyone has | ||
| # messaged the agent. Normally leave empty — they are learned from the first message and saved to | ||
| # .agent-identity.json. agent instance = the app id of the agent instance, user = its agentic user id. | ||
| AGENT_INSTANCE_ID= | ||
| AGENT_USER_ID= | ||
|
|
||
|
|
||
| # ============================================================================= | ||
| # 6. A365 HOSTED-AGENT AUTH (agentic identity, no manual token refresh) | ||
| # ============================================================================= | ||
| USE_AGENTIC_AUTH=true | ||
|
|
||
| # Values below come from the Entra ID app registration that A365 provisions for | ||
| # your hosted-agent project. Get them from: Azure portal → App registrations | ||
| connections__service_connection__settings__clientId=<CHANGE_ME_agent_client_id> | ||
| connections__service_connection__settings__clientSecret=<CHANGE_ME_agent_client_secret> | ||
| connections__service_connection__settings__tenantId=<CHANGE_ME_tenant_id> | ||
|
|
||
| connectionsMap__0__serviceUrl=* | ||
| connectionsMap__0__connection=service_connection | ||
|
|
||
| agentic_type=agentic | ||
| agentic_altBlueprintConnectionName=service_connection | ||
| agentic_scopes=https://graph.microsoft.com/.default | ||
| agent_id=<CHANGE_ME_agent_client_id> | ||
| connections__service_connection__settings__scopes=5a807f24-c9de-44ee-a3a7-329e88a00ffc/.default | ||
| agentic_connectionName=AgenticAuthentication | ||
|
|
||
|
|
||
| # ============================================================================= | ||
| # 7. A365 OBSERVABILITY (Agent 365 telemetry — safe to leave duplicated) | ||
| # ============================================================================= | ||
| # agentId = the runtime Agent Identity (the app id of the agent instance, NOT the blueprint id). The | ||
| # exporter authenticates as this identity; the live id is read from each turn and this is only the fallback. | ||
| # Find it in the "[A365 Observability] App-only export token acquired for agent <id>" startup log line. | ||
| agent365Observability__agentId=<CHANGE_ME_agent_identity_app_id> | ||
| agent365Observability__agentName=EmployeeCareerCoachIdentity | ||
| agent365Observability__agentDescription=EmployeeCareerCoach | ||
| agent365Observability__tenantId=<CHANGE_ME_tenant_id> | ||
| # agentBlueprintId = the blueprint's app id (a365.generated.config.json -> agentBlueprintId). | ||
| agent365Observability__agentBlueprintId=<CHANGE_ME_blueprint_app_id> | ||
| agent365Observability__clientId=<CHANGE_ME_agent_client_id> | ||
| agent365Observability__clientSecret=<CHANGE_ME_agent_client_secret> | ||
|
|
||
|
|
||
| # ============================================================================= | ||
| # 8. SETUP / SEED SCRIPTS (device-code auth, developer only) | ||
| # ============================================================================= | ||
| # setup:sharepoint / seed:reference / mark:complete sign in with MSAL device-code. | ||
| # Defaults: a well-known public Microsoft Graph client + the 'common' tenant. | ||
| # Override only if your tenant blocks the default public client. | ||
| GRAPH_AUTH_CLIENT_ID= | ||
| GRAPH_AUTH_TENANT_ID= | ||
| # Test user for the helper scripts. mark:complete requires TEST_USER_AAD_ID; reset:milestones and | ||
| # backup:user use it when no user id is passed on the command line. Set your test user's AAD object id | ||
| # and display name. | ||
| TEST_USER_AAD_ID= | ||
| TEST_USER_NAME= | ||
| # Optional override for the seed CSV directory (defaults to ./SharePoint Data). | ||
| SP_SEED_CSV_DIR= |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,44 @@ | ||
| # dependencies + build | ||
| node_modules/ | ||
| dist/ | ||
| *.tsbuildinfo | ||
|
|
||
| # TS compile artefacts inside src (only source .ts should be tracked) | ||
| src/**/*.js | ||
| src/**/*.d.ts | ||
| src/**/*.js.map | ||
|
|
||
| # env & secrets — never commit | ||
| .env | ||
| .env.local | ||
| .env.*.local | ||
| .mstoken-cache.json | ||
|
|
||
| # generated at first `a365` run — contains tenant/agent IDs | ||
| a365.config.json | ||
| a365.generated.config.json | ||
| .a365-workspace-detection.local.json | ||
|
|
||
| # runtime state + backups | ||
| .proactive-storage.json | ||
| .proactive-refs.json | ||
| .sp-subscription.json | ||
| .email-plans.json | ||
| .agent-identity.json | ||
| .portal-queue.json | ||
| .completion-email-receipts.json | ||
| .completion-email-receipts.json.*.tmp | ||
| backups/ | ||
|
|
||
| # dev logs | ||
| dev.log | ||
| *.log | ||
|
|
||
| # packaged Teams app | ||
| manifest/manifest.zip | ||
|
|
||
| # agent skills installed via `gh skill add microsoft/agent365-skills` — workspace-local | ||
| .agents/ | ||
| .claude/ | ||
| .github/copilot-instructions.md | ||
| .github/copilot-instructions.md.bak | ||
Oops, something went wrong.
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.