This guide will help you set up your local development environment for working on the Essential C# Web project.
- Visual Studio (or your preferred IDE)
- .NET 10.0 SDK — verify with
dotnet --info
For basic browsing and UI development, no secrets are needed. The database connection and HCaptcha test keys are already configured in appsettings.Development.json.
- Clone the repository.
- If you have access to the private NuGet feed, set
<AccessToNugetFeed>true</AccessToNugetFeed>in Directory.Packages.props. - Run the project.
Tip: Use the dotnet secret manager for any secrets below:
dotnet user-secrets set "<Key>" "<Value>" --project EssentialCSharp.Web
These features are disabled or use safe defaults in Development unless explicitly configured.
Required to enable the chat widget. Skipped entirely in Development if not configured.
AIOptions:Endpoint = https://<your-azure-openai-resource>.openai.azure.com/
AIOptions:VectorGenerationDeploymentName = text-embedding-3-large-v1
AIOptions:ChatDeploymentName = gpt-4o
ConnectionStrings:PostgresVectorStore = <postgres-connection-string>
The MCP endpoint (/mcp) is always running. To generate tokens via the Account > MCP Access page, no additional config is needed — tokens are stored in the local database.
TryDotNet:Origin = https://<trydotnet-origin>
Use one of these — not both simultaneously (they conflict).
# Azure Monitor (Application Insights):
APPLICATIONINSIGHTS_CONNECTION_STRING = InstrumentationKey=...
# Local Aspire dashboard (OTLP):
OTEL_EXPORTER_OTLP_ENDPOINT = http://localhost:4317
These are only required outside of Development. The app throws at startup if they are missing in non-Development environments.
AuthMessageSender:SendFromName = Hello World Team
AuthMessageSender:SendFromEmail = no-reply@email.com
AuthMessageSender:SecretKey = <mailjet-secret-key>
AuthMessageSender:APIKey = <mailjet-api-key>
Authentication:Microsoft:ClientId = <client-id>
Authentication:Microsoft:ClientSecret = <client-secret>
Authentication:github:clientId = <client-id>
Authentication:github:clientSecret = <client-secret>
Development uses hCaptcha test keys by default. Override for production:
HCaptcha:SiteKey = <site-key>
HCaptcha:SecretKey = <secret-key>