---
title: "Price a configuration, and record it when a key is presented"
method: POST
path: "/api/v1/quote"
tags: ["Pricing"]
---

# Price a configuration, and record it when a key is presented

`POST /api/v1/quote`

## Request

- Base URL: `https://api.riskrouter.eu`
- URL: `https://api.riskrouter.eu/api/v1/quote`
- Auth: one of:
  - none
  - HTTP bearer
  - API key in header `X-RiskRouter-Key`

The server prices every quote from its own matrix and ignores any price a client sends. Mandatory base layers are always included. Without a key the quote is priced and nothing is written. With a valid key it is also appended to the ledger; check `persistence.persisted` (or `attribution.recorded`), because a 200 prices the quote even when the ledger refused the write. An invalid, revoked or suspended key is refused with 401 and never downgraded to anonymous.

## Headers

- `Idempotency-Key` string

## Request body

- QuoteRequest
  - `active_vertical` 'mobility' | 'digital_nomad' | 'urban_rental' | 'micro_travel', required
  - `selected_components` object: Add-on code to boolean. Unknown codes are reported in `ignored_components`, never priced. Omit for base layer only.

## Response `200`

Priced. Whether it was recorded is in `persistence` and `attribution`.

- QuoteResponse
  - `ok` boolean
  - `quote` object
    - `quote_reference` string, uuid
    - `active_vertical` string
    - `currency` 'EUR'
    - `billing_interval` 'MONTHLY'
    - `selected_components` object
    - `ignored_components` string[]
    - `line_items` object[]
    - `totals` object
      - `base_layer_premium` string: EUR, exactly two decimals, as a string. Never a float.
      - `add_on_premium` string: EUR, exactly two decimals, as a string. Never a float.
      - `total_monthly_premium` string: EUR, exactly two decimals, as a string. Never a float.
      - `indicative_annual_premium` string: EUR, exactly two decimals, as a string. Never a float.
      - `active_add_on_count` integer
  - `attribution` object
    - `recorded` boolean: True only when the ledger accepted the entry.
    - `mode` 'ANONYMOUS' | 'ATTRIBUTED'
    - `distributor` string
    - `environment` 'sandbox' | 'production'
    - `note` string
  - `persistence` object
    - `attempted` boolean
    - `persisted` boolean
    - `record_id` string
    - `seal` object
      - `chain_index` integer
      - `row_hash` string
      - `prev_hash` string
    - `detail` string
    - `replayed` boolean: True when an earlier request with the same Idempotency-Key recorded this entry; nothing new was written.
    - `idempotency_key` string
  - `compliance` object
  - `engine` object
  - `generated_at` string, date-time

## Other responses

- `400`: Every error carries the same envelope with a stable code.
- `401`: Every error carries the same envelope with a stable code.
- `409`: Every error carries the same envelope with a stable code.
- `413`: Every error carries the same envelope with a stable code.
- `415`: Every error carries the same envelope with a stable code.
- `429`: Every error carries the same envelope with a stable code.

---

[API](https://skmtc.dev/riskrouter/apis/riskrouter-api.md) · [All operations](https://skmtc.dev/riskrouter/apis/riskrouter-api/llms.txt) · [OpenAPI document](https://skmtc.dev/riskrouter/apis/riskrouter-api/revisions/5fee45dc6d1f?raw)
