Initial commit
This commit is contained in:
43
src/RolemasterDb.App/Components/Pages/Api.razor
Normal file
43
src/RolemasterDb.App/Components/Pages/Api.razor
Normal file
@@ -0,0 +1,43 @@
|
||||
@page "/api"
|
||||
|
||||
<PageTitle>API Surface</PageTitle>
|
||||
|
||||
<section class="hero-panel">
|
||||
<span class="eyebrow">Minimal API</span>
|
||||
<h1 class="page-title">Endpoints for attack and critical lookups.</h1>
|
||||
<p class="lede">The Blazor UI uses the same lookup service that the API exposes, so this page doubles as the first integration contract.</p>
|
||||
</section>
|
||||
|
||||
<div class="api-grid">
|
||||
<section class="panel">
|
||||
<h2 class="panel-title">Reference data</h2>
|
||||
<p class="panel-copy"><code>GET /api/reference-data</code></p>
|
||||
<pre class="code-block">{
|
||||
"attackTables": [
|
||||
{ "key": "broadsword", "label": "Broadsword" }
|
||||
]
|
||||
}</pre>
|
||||
</section>
|
||||
|
||||
<section class="panel">
|
||||
<h2 class="panel-title">Attack lookup</h2>
|
||||
<p class="panel-copy"><code>POST /api/lookup/attack</code></p>
|
||||
<pre class="code-block">{
|
||||
"attackTable": "broadsword",
|
||||
"armorType": "AT10",
|
||||
"roll": 111,
|
||||
"criticalRoll": 72
|
||||
}</pre>
|
||||
</section>
|
||||
|
||||
<section class="panel">
|
||||
<h2 class="panel-title">Critical lookup</h2>
|
||||
<p class="panel-copy"><code>POST /api/lookup/critical</code></p>
|
||||
<pre class="code-block">{
|
||||
"criticalType": "slash",
|
||||
"column": "B",
|
||||
"roll": 72,
|
||||
"group": null
|
||||
}</pre>
|
||||
</section>
|
||||
</div>
|
||||
Reference in New Issue
Block a user