Files
llmgw/internal/web/templates/claim.html
T
Ilker ManapandClaude Opus 5.5 f8d18efaef Turkish pages are Turkish to the end
The errors other packages give a page (store, catalog, mirror) are
shown in its language; a percentage is written as the language writes
it (%93 in Turkish); the footer's time in its date form; and a stale
form is refused with a sentence rather than "bad request".

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
2026-10-21 09:22:42 +02:00

45 lines
1.4 KiB
HTML

{{define "claim"}}<!doctype html>
<html lang="{{lang}}"><head>
<meta charset="utf-8"><meta name="viewport" content="width=device-width,initial-scale=1">
<meta name="robots" content="noindex, nofollow">
<title>{{t "claim.title"}}</title><link rel="stylesheet" href="{{stylesheet}}">
</head><body><div class="wrap">
<header>
<h1>{{t "claim.heading"}}</h1>
<p class="sub" translate="no">llmgw · {{.BaseURL}}</p>
</header>
{{if .Secret}}
<p>{{t "claim.shown_once"}}</p>
<pre>{{.Secret}}</pre>
<p>{{t "claim.store_it"}}</p>
<h2>{{t "claim.using_it"}}</h2>
<pre>export LLMGW_API_KEY={{.Secret}}
curl {{.BaseURL}}/v1/chat/completions \
-H "Authorization: Bearer $LLMGW_API_KEY" \
-H "Content-Type: application/json" \
-d '{"model": "&lt;model-name&gt;", "messages": [{"role":"user","content":"hello"}]}'</pre>
<p class="note">
{{th "claim.replace_placeholder" .BaseURL}}
</p>
<pre>from openai import OpenAI
client = OpenAI(base_url="{{.BaseURL}}/v1", api_key=os.environ["LLMGW_API_KEY"])</pre>
<p class="note">{{th "claim.endpoints" .BaseURL}}</p>
{{else if .Gone}}
<p>{{.Message}}</p>
<p class="note">{{t "claim.ask_again"}}</p>
{{else}}
<p>{{t "claim.issued"}}</p>
<form method="post">
<button type="submit">{{t "claim.reveal"}}</button>
</form>
<p class="note">{{t "claim.expires" .ExpiresAt}}</p>
{{end}}
<footer><span>llmgw {{.Version}}</span><span>{{stamp .Now}}</span>{{template "langs"}}</footer>
</div></body></html>{{end}}