writing-csharp-code
C# Coding Standards
Goal: Write clean, secure ASP.NET Core code with proper authentication
Hot Reload Development Workflow
The backend runs in watch mode (dotnet watch run). When you edit C# code:
- Save the file - .NET automatically recompiles
- Check the terminal - Look for compilation output in the "Backend: ASP.NET Core API" terminal
- Verify via console logs - New requests will use updated code immediately
VS Code Tasks (use Run Task command or check terminal panel):
Backend: ASP.NET Core API- Runsdotnet watch runwith live recompilation- Logs are visible directly in VS Code terminal
No restart needed - Just edit, save, and test. Watch for compilation errors in the terminal.
Testing changes: Use Playwright browser tools to make requests and check browser console logs, or call endpoints directly.
More from microsoft-foundry/foundry-agent-webapp
writing-bicep-templates
Provides Bicep coding standards for Azure infrastructure in this repository. Use when writing or modifying Bicep files, configuring Container Apps, setting up RBAC, or working with Azure resources.
38writing-typescript-code
Provides TypeScript and React coding standards for this repository. Use when writing or modifying TypeScript code, creating React components, implementing MSAL authentication, or working with the frontend.
12deploying-to-azure
Provides deployment commands and troubleshooting for Azure Container Apps. Use when running azd commands, deploying containers, debugging deployment failures, or updating infrastructure in this repository.
11validating-ui-features
Provides step-by-step procedures for validating UI features - theme toggle, new chat, cancel stream, markdown rendering, and token usage info.
10troubleshooting-authentication
Provides authentication troubleshooting for MSAL, JWT, and Entra ID. Use when debugging 401 errors, token issues, MSAL configuration problems, or credential failures in this repository.
10implementing-chat-streaming
Provides SSE streaming patterns for the chat API and frontend. Use when implementing or modifying chat streaming, handling SSE events, or troubleshooting message flow between frontend and backend.
9