# System.Configuration

**Kind:** Service

**Source:** `Pams/Data/Pams.Data/Pams.Data.csproj` (line 1)

**Part of:** [Pams](subsystem-pams)

NuGet package dependency

`System.Configuration` is a NuGet dependency declared by `Pams.Data.csproj`. It provides .NET configuration APIs that the data project can use to read application settings and connection-string configuration from legacy configuration files.

## Diagram

```mermaid
graph TD
    PamsData[Pams.Data project] --> Package[System.Configuration NuGet package]
    Package --> Config[Application configuration]
    Config --> DataAccess[Pams.Data configuration access]
```

## Usage

```javascript
import { readFile } from "node:fs/promises";

const projectFile = "Pams/Data/Pams.Data/Pams.Data.csproj";
const projectXml = await readFile(projectFile, "utf8");

if (!projectXml.includes("System.Configuration")) {
  throw new Error(
    "Pams.Data requires the System.Configuration package reference."
  );
}

console.log("System.Configuration dependency is declared.");
```

## AI Coding Instructions

- Keep `System.Configuration` references aligned with the dependency format already used by `Pams.Data.csproj`.
- Treat configuration values as deployment input; do not hard-code connection strings or environment-specific settings in `Pams.Data`.
- Check the consuming application’s configuration file when a setting or connection string cannot be resolved.
- Do not add JavaScript runtime imports for this package; it is consumed by the .NET project.

## Used by

1 reference from 1 file. Each is a place in this repository where the symbol is actually used — go read one rather than trusting an example.

### Injected or called by (1)

- `Pams.Data` — `Pams/Data/Pams.Data/Pams.Data.csproj`:1
