# Microsoft.AspNet.Identity.EntityFramework

**Kind:** Service

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

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

NuGet package dependency

`Microsoft.AspNet.Identity.EntityFramework` is a NuGet package dependency declared by `Pams.API.csproj`. It connects the legacy ASP.NET Identity model to Entity Framework storage used by the Pams API authentication and authorization code.

## Diagram

```mermaid
sequenceDiagram
    participant Build as Pams.API.csproj
    participant NuGet as NuGet Restore
    participant Identity as Microsoft.AspNet.Identity.EntityFramework
    participant EF as Entity Framework Store

    Build->>NuGet: Restore package dependency
    NuGet->>Identity: Resolve identity Entity Framework package
    Identity->>EF: Configure identity data stores
    Build->>Identity: Reference identity persistence types
```

## Usage

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

const projectFile = "Pams/API/Pams.API/Pams.API.csproj";
const packageName = "Microsoft.AspNet.Identity.EntityFramework";

const projectXml = await readFile(projectFile, "utf8");

if (projectXml.includes(packageName)) {
  console.log(`${packageName} is declared in ${projectFile}`);
} else {
  throw new Error(`${packageName} is not declared in ${projectFile}`);
}
```

## AI Coding Instructions

- Keep `Microsoft.AspNet.Identity.EntityFramework` aligned with the ASP.NET Identity packages referenced by the API project.
- Check the legacy project file dependency format before changing package references or restore configuration.
- Treat identity persistence changes as API integration changes because authentication code may depend on Entity Framework-backed identity stores.
- Verify package restore and project build output after modifying `Pams.API.csproj`.

## 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.API` — `Pams/API/Pams.API/Pams.API.csproj`:1
