added support for robots.txt and llm.txt so bots and ai agents can fetch the subdomain
This commit is contained in:
@@ -71,6 +71,81 @@ app.use(express.json());
|
||||
app.use(express.urlencoded({ extended: false }));
|
||||
app.get('/', (req, res) => res.sendFile(path.join(__dirname, '..', 'client.html')));
|
||||
|
||||
// robots.txt with Cloudflare's Content Signals Policy — explicitly allows
|
||||
// search indexing, AI input (RAG/grounding/real-time retrieval), and AI
|
||||
// training. Previously there was no route for this at all, so Express fell
|
||||
// through to its default 404 handler for every request to /robots.txt.
|
||||
app.get('/robots.txt', (req, res) => {
|
||||
res.type('text/plain');
|
||||
res.send(
|
||||
`# As a condition of accessing this website, you agree to abide by the following
|
||||
# content signals:
|
||||
|
||||
# (a) If a content-signal = yes, you may collect content for the corresponding
|
||||
# use.
|
||||
# (b) If a content-signal = no, you may not collect content for the
|
||||
# corresponding use.
|
||||
# (c) If the website operator does not include a content signal for a
|
||||
# corresponding use, the website operator neither grants nor restricts
|
||||
# permission via content signal with respect to the corresponding use.
|
||||
|
||||
# The content signals and their meanings are:
|
||||
|
||||
# search: building a search index and providing search results (e.g., returning
|
||||
# hyperlinks and short excerpts from your website's contents). Search does not
|
||||
# include providing AI-generated search summaries.
|
||||
# ai-input: inputting content into one or more AI models (e.g., retrieval
|
||||
# augmented generation, grounding, or other real-time taking of content for
|
||||
# generative AI search answers).
|
||||
# ai-train: training or fine-tuning AI models.
|
||||
|
||||
# ANY RESTRICTIONS EXPRESSED VIA CONTENT SIGNALS ARE EXPRESS RESERVATIONS OF
|
||||
# RIGHTS UNDER ARTICLE 4 OF THE EUROPEAN UNION DIRECTIVE 2019/790 ON COPYRIGHT
|
||||
# AND RELATED RIGHTS IN THE DIGITAL SINGLE MARKET.
|
||||
|
||||
User-Agent: *
|
||||
Content-Signal: search=yes, ai-input=yes, ai-train=yes
|
||||
Allow: /
|
||||
`
|
||||
);
|
||||
});
|
||||
|
||||
// llms.txt — a concise, Markdown summary purpose-built for AI agents/LLMs to
|
||||
// understand and describe the site (distinct from robots.txt, which only
|
||||
// controls access/usage permissions, not comprehension).
|
||||
app.get('/llms.txt', (req, res) => {
|
||||
res.type('text/plain');
|
||||
res.send(
|
||||
`# UNLOZE Webclient
|
||||
|
||||
> A free, browser-based streaming client for Counter-Strike Source (CSS).
|
||||
> No Steam account, no download, and no installation required — the game
|
||||
> runs server-side and streams to your browser via WebRTC.
|
||||
|
||||
## What this is
|
||||
|
||||
UNLOZE Webclient lets anyone play Counter-Strike Source directly in a web
|
||||
browser, streamed from a server-hosted instance of the game. This is aimed
|
||||
at players who don't own CSS on Steam or don't want to install it locally.
|
||||
|
||||
Only one visitor controls the game at a time (via a queue system); others
|
||||
can watch the live stream while waiting their turn.
|
||||
|
||||
## Available game modes
|
||||
|
||||
- Zombie Escape — ze.unloze.com:27015
|
||||
- Zombie Escape 2 — ze.unloze.com:27035
|
||||
- Minigames — mg.unloze.com:27017
|
||||
- Zombie Riot — zr.unloze.com:27016
|
||||
|
||||
## Related links
|
||||
|
||||
- Main community site: https://unloze.com
|
||||
- Counter-Strike Source on Steam: https://store.steampowered.com/app/240/CounterStrike_Source/
|
||||
`
|
||||
);
|
||||
});
|
||||
|
||||
// ── Internal-request gate ─────────────────────────────────────────────────────
|
||||
// Used by /webclient-name (POST), /webclient-current-ip (GET), and
|
||||
// /webclient-force-restart (POST) — all internal-only endpoints intended for
|
||||
|
||||
Reference in New Issue
Block a user