# API Overview

Parametrig's public API surface is served from the canonical Auk product base at
`https://api.parametrig.com/auk/v1`.

## Public API Principles

- one canonical backend source of truth
- programmatic access first
- browser surfaces are clients, not the authority
- stable external contracts should not depend on UI-specific behavior

## Current Public Family

The current published API family starts with Auk.

This docs surface should expand only when public contract material is ready to
be durable, discoverable, and supportable. Internal product families or engine
boundaries should not appear here just because they already exist behind the
current backend.

## Surface Families

Additional named surfaces may be published later as they become real external
contracts, but they should not appear here before their product and trust
boundaries are actually ready.

As public API references expand, this docs site should become the home for:

- endpoint overviews
- authentication guidance
- webhook/event guidance
- examples and integration notes

## Current Reference Foundations

The first concept pages now anchor the public API shape:

- [Authentication](/api/authentication/)
- [Events](/api/events/)
- [Policies](/api/policies/)
- [Claims and payouts](/api/claims-and-payouts/)
- [Webhooks](/api/webhooks/)

## Illustrative Request Posture

<div class="code-tabs">
  <button class="code-tab active" data-tab="api-tab-curl">cURL</button>
  <button class="code-tab" data-tab="api-tab-python">Python</button>
  <button class="code-tab" data-tab="api-tab-typescript">TypeScript</button>
</div>
<div class="tab-panel active" id="api-tab-curl">
```bash
curl https://api.parametrig.com/auk/v1/quotes \
  -H "Authorization: Bearer <token>" \
  -H "Content-Type: application/json" \
  -d '{"product":"auk","context":{"partner":"demo"}}'
```
</div>
<div class="tab-panel" id="api-tab-python">
```python
import requests

response = requests.post(
    "https://api.parametrig.com/auk/v1/quotes",
    headers={"Authorization": "Bearer <token>"},
    json={"product": "auk", "context": {"partner": "demo"}},
)
```
</div>
<div class="tab-panel" id="api-tab-typescript">
```ts
const response = await fetch("https://api.parametrig.com/auk/v1/quotes", {
  method: "POST",
  headers: {
    Authorization: "Bearer <token>",
    "Content-Type": "application/json",
  },
  body: JSON.stringify({ product: "auk", context: { partner: "demo" } }),
});
```
</div>

## Lifecycle Expectation

As the public reference expands, this docs surface should become the home for:

- request and response examples
- auth guidance
- event and webhook semantics
- error behavior
- versioning expectations
- support and escalation boundaries

## Publication Rule

Public API material belongs here only when it is ready to be treated as a
public-facing contract.
