Portal Community
Do not edit appsettings.json Editing the base file causes conflicts for every other developer the moment you pull or they pull. All machine-specific settings go in your Local file.

Where to Create the File

Create appsettings.Development.Local.json in the same folder as appsettings.json:

src/mvc-server/Solutions/AiUltimate/BizFirst.Ai.Consolidated.WebApi/
├── appsettings.json                       ← do not edit
├── appsettings.Development.json           ← do not edit
└── appsettings.Development.Local.json     ← create this

Step-by-Step Setup

1

Create appsettings.Development.Local.json

Replace YOUR_SERVER with your machine name (e.g. ACHU, LAPTOP-ABC123).

{
  "ConnectionStrings": {
    "DefaultConnection": "Data Source=YOUR_SERVER\\SQLEXPRESS;Initial Catalog=BIZFIRSTATLASDB;Integrated Security=True;Connect Timeout=29;Encrypt=Optional;TrustServerCertificate=True"
  },
  "BizFirstAIDatabase": {
    "Default": "Data Source=YOUR_SERVER\\SQLEXPRESS;Initial Catalog=BIZFIRSTATLASDBV18;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Encrypt=True;TrustServerCertificate=True;Application Name=SQL Server Management Studio;Command Timeout=0",
    "DefaultConnection": {
      "Master": "Data Source=YOUR_SERVER\\SQLEXPRESS;Initial Catalog=BIZFIRSTATLASDBV18;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Encrypt=True;TrustServerCertificate=True;Application Name=SQL Server Management Studio;Command Timeout=0"
    },
    "BizFirstAI": {
      "Master": "Data Source=YOUR_SERVER\\SQLEXPRESS;Initial Catalog=BIZFIRSTATLASDBV18;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Encrypt=True;TrustServerCertificate=True;Application Name=SQL Server Management Studio;Command Timeout=0"
    }
  },
  "Database": {
    "BizFirstAI": {
      "Master": "Data Source=YOUR_SERVER\\SQLEXPRESS;Initial Catalog=BIZFIRSTATLASDBV18;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Encrypt=True;TrustServerCertificate=True;Application Name=SQL Server Management Studio;Command Timeout=0"
    }
  },
  "SqlServerAtlasStorage": {
    "ConnectionString": "Data Source=YOUR_SERVER\\SQLEXPRESS;Initial Catalog=BIZFIRSTATLASDBV18;Integrated Security=True;Persist Security Info=False;Pooling=False;MultipleActiveResultSets=False;Encrypt=True;TrustServerCertificate=True;Application Name=SQL Server Management Studio;Command Timeout=0"
  }
}
2

Verify launchSettings.json

Confirm ASPNETCORE_ENVIRONMENT is set to Development so your Local file is picked up:

{
  "profiles": {
    "BizFirst.Ai.Consolidated.WebApi": {
      "environmentVariables": {
        "ASPNETCORE_ENVIRONMENT": "Development",
        "TENANT_CODE": "bizfirst"
      },
      "applicationUrl": "https://localhost:10001;http://localhost:5001"
    }
  }
}
3

Run the app

Press F5 in Visual Studio or run:

dotnet run

Your Local file overrides the base connection strings. The app connects to your SQL Server instance.

What the File Can Override

Your Local file can override any key from the base files. Common overrides:

SettingWhy you might override it
SQL Server connection stringsYour local instance has a different server name
Redis connection stringYou run Redis on a non-default port or with auth
Kafka bootstrap serversYour local Kafka broker is on a different port
Log levelsYou want Debug for a specific namespace
Loki / Grafana endpointsYou run a local observability stack
LLM API keyYou use your own OpenAI key for development
Gitignored by default appsettings.*.Local.json is already in .gitignore. Git will refuse to stage it — you cannot accidentally commit it even if you try.

Common Mistakes

MistakeFix
Editing appsettings.json with your server nameMove the value to your Local file and revert the base file
Local file not being picked upCheck ASPNETCORE_ENVIRONMENT=Development matches the {env} in the file name
App still connecting to wrong databaseVerify the JSON key path matches exactly — it is case-insensitive on Windows but not on Linux
File created in wrong folderMust be in the same folder as appsettings.json, not the project root