[← Docs](/docs/)  |  [Home](/)

# RunProof Free キー発行（v1.2）
<div style="font-size:12px;color:#555">RunProof Free Key Issuance (v1.2)</div>

この文書は、**Freeプラン**の「キー発行フロー」を凍結します。Freeは **完全放置（自動発行）** を前提に設計します。

<div style="font-size:12px;color:#555">This document freezes the Free plan key issuance flow. Free is designed for fully self-serve issuance.</div>

- Last-Updated: 2026-03-17
- Free plan intent: 評価用の小規模デモ — **全プランで同一のレシート形式・検証フロー**
<div style="font-size:12px;color:#555">Free is a small demo tier to evaluate behavior with real outputs. All plans share the same receipt format and verification flow.</div>

---

## Free プラン（公開）
- レシート/月：**10**
- project：**1**
- APIキー：**1**
- 出力品質：全プランで同一のレシート形式・検証フロー
<div style="font-size:12px;color:#555">Free: 10 receipts/month, 1 project, 1 API key. Same receipt/verification format across all plans.</div>

---

## 発行フロー（完全放置）
1. 利用者が **`/free/claim/`** を開く
2. Turnstile（人間確認）を1回通す
3. `POST /v1/claim/free` が **新規 project + APIキー** を発行
4. 生キーは **one-time reveal（show=1）**：短期保持は表示ウィンドウのための TTL（例：10分）であり、**再表示のためではない**
5. D1には **ハッシュのみ**保存（生キーは保存しない）

<div style="font-size:12px;color:#555">Flow: open /free/claim/ → pass Turnstile → POST /v1/claim/free → one-time reveal (show=1) with a short TTL window for initial display only. A second reveal returns already_claimed. Only the hash is stored in D1.</div>

- `show=1` 固定（2回目以降は **`already_claimed`**）
- TTL は初回表示ウィンドウのためだけに使う。**再表示回数の救済には使わない**
- 紛失時は再表示ではなく、制限の下での**新規発行/再発行**で扱う

<div style="font-size:12px;color:#555">`show=1` is fixed. A second reveal returns <code>already_claimed</code>. TTL is only for the initial display window, not for extra reveals. Lost keys are handled by re-issuance, not re-reveal.</div>

---

## 乱用防止（最低限）
- **1 IP あたり 1日1回**（KVロック）
- 同一端末の短期連打はできない
- Freeの再発行は基本不要：紛失時は **翌日以降に再度 /free/claim/**（回数制限が自然ブレーキ）

<div style="font-size:12px;color:#555">Anti-abuse: 1 issuance per IP per day. Lost keys are re-issued via /free/claim/ on a later day.</div>
