Skip to content

Microsoft.EntityFrameworkCore.SqlServer

reference
1 min readUpdated

Kind: Service

Source: Pams/API/Pams.API.Core/Pams.API.Core.csproj (line 1)

Part of: Pams

NuGet package dependency

Microsoft.EntityFrameworkCore.SqlServer is a NuGet package dependency in Pams.API.Core.csproj. It connects Entity Framework Core data access code in the API to SQL Server through the configured DbContext.

Diagram

mermaid
sequenceDiagram
    participant Client
    participant API as Pams API
    participant EF as Entity Framework Core
    participant SQL as SQL Server

    Client->>API: Send API request
    API->>EF: Query or save entity data
    EF->>SQL: Execute SQL command
    SQL-->>EF: Return result
    EF-->>API: Map result to application data
    API-->>Client: Return response

Usage

ts
const response = await fetch("/api/pams/items", {
  method: "GET",
  headers: {
    Accept: "application/json",
  },
});

if (!response.ok) {
  throw new Error("Unable to load items from the API.");
}

const items = await response.json();
console.log(items);

AI Coding Instructions

  • Keep Microsoft.EntityFrameworkCore.SqlServer referenced from Pams.API.Core.csproj when the API uses SQL Server-backed Entity Framework Core contexts.
  • Configure SQL Server access in the API startup path through the application DbContext and connection string settings.
  • Do not import this .NET package from TypeScript or JavaScript clients; client code should call API endpoints instead.
  • Keep database queries and persistence logic in the API layer rather than exposing SQL Server details through API responses.

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.CorePams/API/Pams.API.Core/Pams.API.Core.csproj:1

Was this page helpful?

Download as PDF