> ## Documentation Index
> Fetch the complete documentation index at: https://docs.prysm1.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Get savings

> Estimate how much you saved versus routing every request to a single baseline model.

<Note>
  **GET** `https://api.prysm1.com/v1/savings` · Requires authentication
</Note>

Computes an estimate of what your usage would have cost if every request had gone to a
single baseline model, then returns the delta against your actual spend. The figure is a
blended estimate based on per-token pricing — it is not a billing statement.

## Authorization

<ParamField header="Authorization" type="string" required>
  Your secret key as a bearer token: `Bearer prysm_sk_...`
</ParamField>

## Query parameters

<ParamField query="baseline" type="string" default="gpt-5.2">
  The model to compare against. Must be a valid model ID from
  [`GET /v1/models`](/api-reference/models). Defaults to `gpt-5.2`.
</ParamField>

## Response

<ResponseField name="baseline_model" type="string">The model used as the comparison baseline.</ResponseField>
<ResponseField name="total_requests" type="integer">Total requests included in the calculation.</ResponseField>
<ResponseField name="total_tokens" type="integer">Total tokens (input + output) across all requests.</ResponseField>
<ResponseField name="actual_cost_usd" type="number">Your actual spend, USD.</ResponseField>
<ResponseField name="baseline_cost_usd" type="number">Estimated cost if every request had gone to the baseline model, USD.</ResponseField>
<ResponseField name="saved_usd" type="number">Estimated savings: `max(0, baseline_cost - actual_cost)`, USD.</ResponseField>
<ResponseField name="saved_pct" type="number">Percentage saved relative to the baseline cost.</ResponseField>

<RequestExample>
  ```python Python theme={null}
  from prysm import Prysm

  client = Prysm()
  s = client.savings(baseline="gpt-5.2")
  print(f"Saved ${s['saved_usd']:.4f} ({s['saved_pct']:.1f}%)")
  ```

  ```typescript Node theme={null}
  import { Prysm } from "@prysmai/sdk";

  const client = new Prysm();
  const s = await client.savings("gpt-5.2");
  console.log(`Saved $${s.saved_usd.toFixed(4)} (${s.saved_pct.toFixed(1)}%)`);
  ```

  ```bash cURL theme={null}
  curl "https://api.prysm1.com/v1/savings?baseline=gpt-5.2" \
    -H "Authorization: Bearer $PRYSM_API_KEY"
  ```
</RequestExample>

<ResponseExample>
  ```json 200 theme={null}
  {
    "baseline_model": "gpt-5.2",
    "total_requests": 128,
    "total_tokens": 512340,
    "actual_cost_usd": 0.214500,
    "baseline_cost_usd": 4.109388,
    "saved_usd": 3.894888,
    "saved_pct": 94.77
  }
  ```

  ```json 400 — unknown baseline theme={null}
  {
    "error": "unknown_model",
    "message": "Unknown baseline model 'ghost-model'. See GET /v1/models."
  }
  ```
</ResponseExample>

<Tip>
  Compare against different baselines to see how your routing choices stack up. For
  agentic workloads, `claude-opus-4.6` or `gpt-5.2-pro` make conservative baselines
  that show maximum savings.
</Tip>
