---
title: Endpoint map
summary: Traceability from each client method to the API endpoint it calls, and client-vs-API route drift.
status: draft
owner: Premium Systems Team
last_reviewed: 2026-10-21
---

# Endpoint map

This page traces every remote member of `IPremiumClient` to the `SAIF.Premium.Api` endpoint it calls. It is the page a reader uses to answer "which endpoint does this call hit, which setting supplies its route, and where is that endpoint documented".

| Field | Value |
| --- | --- |
| **Wrapped API** | `SAIF.Premium.Api` |
| **Origin** | Documented by this run |
| **Base URL** | `IEnvironmentClient` setting `premiumbaseurl` (app key `PremiumApi`) |
| **Version segment** | Carried by the route settings (`/v1/...`) |
| **Remote members mapped** | 6 of 7 public members |
| **Route drift findings** | 1 |

## Endpoint map

| Client member | Verb | Setting key | Resolved route | Parameter appending | `IHttpJsonClient` method | Request type | Response type | Endpoint | Reference |
| --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
| `GetPremiumAsync` | GET | `premiumroute` | `/v1/Premiums/{policyNumber}` | `PremiumRoute + policyNumber` | `GetAsync<T>` | - | `PremiumSummary` | `GET /v1/Premiums/{policyNumber}` | Details |
| `GetPremiumHistoryAsync` | GET | `premiumhistoryroute` | `/v1/Premiums/{policyNumber}/history` | `string.Format(PremiumHistoryRoute, policyNumber)` | `GetAsync<T>` | - | `List<PremiumTerm>` | `GET /v1/Premiums/{policyNumber}/history` | Details |
| `EstimatePremiumAsync` | GET | `estimateroute` | `/v1/Premiums/estimate?classCode={classCode}&payroll={payroll}&effectiveDate={effectiveDate}` | `$"{EstimateRoute}?classCode={classCode}&payroll={payroll}&effectiveDate={effectiveDate:yyyy-MM-dd}"` (no URL encoding) | `GetAsync<T>` | - | `PremiumEstimate` | `GET /v1/Premiums/estimate` | Details |
| `AddAdjustmentAsync` | POST | `adjustmentroute` | `/v1/Premiums/{policyNumber}/adjustment` | `string.Format(AdjustmentRoute, policyNumber)` | `PostAsync<T>` | `PremiumAdjustmentRequest` | `PremiumAdjustment` | No matching endpoint - see [Route drift](#route-drift) | Details |
| `GetClassCodeRateAsync` | GET | `classcoderoute` | `/v1/ClassCodes/{classCode}/rate` | `$"{ClassCodeRoute}{classCode}/rate"` | `GetAsync<T>` | - | `ClassCodeRate` | `GET /v1/ClassCodes/{classCode}/rate` | Details |
| `GetCurrentRateTableAsync` | GET | `ratetableroute` | `/v1/RateTables/current` | `RateTableRoute` | `GetAsync<T>` | - | `RateTable` | `GET /v1/RateTables/current` | Details |

Five of the six rows land on an endpoint page generated by this run.
`GetPremiumHistoryAsync` and `AddAdjustmentAsync` build their path with
`string.Format` and a `{0}` placeholder in the setting value, which is why their
Parameter appending cells differ from the plain concatenation used by
`GetPremiumAsync`. `GetCurrentRateTableAsync` is the only member that reaches the
API's minimal API endpoint.

## Route drift

Every remote member is reconciled against the routes [`SAIF.Premium.Api`](../../apis/saif-premium-api/endpoints.md) publishes. A route that matches no endpoint fails at run time with a routing error; the compiler cannot catch it because the route is read from configuration.

| Client member | Verb | Resolved route | Setting key | Closest API route | Finding |
| --- | --- | --- | --- | --- | --- |
| `GetPremiumAsync` | GET | `/v1/Premiums/{policyNumber}` | `premiumroute` | `GET /v1/Premiums/{policyNumber}` | Matches |
| `GetPremiumHistoryAsync` | GET | `/v1/Premiums/{policyNumber}/history` | `premiumhistoryroute` | `GET /v1/Premiums/{policyNumber}/history` | Matches |
| `EstimatePremiumAsync` | GET | `/v1/Premiums/estimate` | `estimateroute` | `GET /v1/Premiums/estimate` | Matches |
| `AddAdjustmentAsync` | POST | `/v1/Premiums/{policyNumber}/adjustment` | `adjustmentroute` | `POST /v1/Premiums/{policyNumber}/adjustments` | **Drift** - client route ends in `adjustment`, API literal is `adjustments`; fails at run time with a 404; see Tech debt |
| `GetClassCodeRateAsync` | GET | `/v1/ClassCodes/{classCode}/rate` | `classcoderoute` | `GET /v1/ClassCodes/{classCode}/rate` | Matches |
| `GetCurrentRateTableAsync` | GET | `/v1/RateTables/current` | `ratetableroute` | `GET /v1/RateTables/current` | Matches |

The drift is a one-character difference in the seeded `adjustmentroute` setting:
the API publishes the collection as `adjustments`, the client posts to
`adjustment`. The request reaches the service and returns `404`, which is
indistinguishable from a missing policy.

### Endpoints not called by the client

| API endpoint | Why the client does not call it |
| --- | --- |
| `GET /v2/ClassCodes/{classCode}/rate` | The client targets `v1` only; no member or setting selects `v2` |
| `POST /v1/Admin/RecalculateBatch` | Administrative endpoint; no client member wraps it |
| `POST /v1/Premiums/{policyNumber}/adjustments` | Intended target of `AddAdjustmentAsync`; missed because of the drift above |

## Unmapped members

Members below are part of the public surface but call no endpoint. They are listed here so the map is provably complete against Client reference.

| Client member | Why unmapped |
| --- | --- |
| `NormalizePolicyNumber(string)` | Local computation - trims and upper-cases a policy number; issues no request |

## Coverage

| Check | Result |
| --- | --- |
| Public members in `IPremiumClient` | 7 |
| Rows in the endpoint map | 6 |
| Rows in unmapped members | 1 |
| Every mapped row resolves, is †-marked, or is unresolved with a reason | No - 5 of 6 resolve; `AddAdjustmentAsync` matches no endpoint (see Route drift) |
| Remote members reconciled in Route drift | 6 |

## Related documentation
- Client index
- Overview
- Architecture
- [Package](package.md)
- Client reference
- [Consumption](consumption.md)
- Contracts
- Dependencies
- Business rules
- Tech debt

> **Note:** Statements marked with † were retrieved from dependency library documentation
> via the Legends CLI RAG service. They describe inherited behavior from the indicated
> origin library and should be verified if the dependency version changes.

## Sources
- `src/SAIF.Premium.Api.Client/IPremiumClient.cs`
- `src/SAIF.Premium.Api.Client/PremiumClient.cs`
- `src/SAIF.Premium.Api.Client/PremiumClientConfiguration.cs`
- `src/SAIF.Premium.Api/Controllers/PremiumsController.cs`
- `src/SAIF.Premium.Api/Controllers/ClassCodesController.cs`
- `src/SAIF.Premium.Api/Controllers/AdminController.cs`
- `src/SAIF.Premium.Api/Endpoints/RateTableEndpoints.cs`
- `environmentsettings/settings.yml`
