Commit 06353568 by PLN (Algolia)

docs(douanier): scrub internal codename from the public OpenAPI surface

The /docs + /openapi.json title read "Douanier — the audio sub-API…" and
/healthz returned service:"douanier" — internal codename leaking to consumers.

- FastAPI title → "Nech.PL Audio Intelligence API"; description rewritten to
  describe the engines (no "customs gate" framing).
- /healthz service → "nech-audio".
- Regenerated clients/openapi.json snapshot (info.title now clean; 13 paths,
  servers=api.nech.pl/audio/v1) — feeds the generated-client pipeline (#44).

Built + redeployed; verified at the edge: openapi.json info.title and healthz
both clean. "Douanier" now survives only as the internal repo/metric name.
67 tests green.
parent 5e7aefb6
...@@ -25,11 +25,12 @@ from engines import grade as grade_eng # VENDORED copy of the Foundry grader ...@@ -25,11 +25,12 @@ from engines import grade as grade_eng # VENDORED copy of the Foundry grader
from engines import naming as naming_eng # VENDORED copy of the Foundry namer (see engines/naming.py) from engines import naming as naming_eng # VENDORED copy of the Foundry namer (see engines/naming.py)
app = FastAPI( app = FastAPI(
title="Douanier — the `audio` sub-API of the nech.pl platform", title="Nech.PL Audio Intelligence API",
version="0.1.0", version="0.1.0",
description="Customs gate over the fleet's audio-intelligence engines. Served " description="Stem-aware audio analysis — emotion, features, sample role, loop "
"publicly at /audio/v1/...; the platform gateway does central auth + " "grading, onsets/tempo, waveform & spectrogram, loudness, naming. "
"metering and injects X-Tenant/X-Scopes. See SRE.md + DEPLOY.md.", "The `audio` API of the Nech.PL APIs platform, served at /audio/v1/...; "
"the gateway does central auth + metering (Bearer token).",
# internal paths (gateway strips /audio/v1 and proxies here at root); root_path # internal paths (gateway strips /audio/v1 and proxies here at root); root_path
# makes /openapi.json + docs advertise the PUBLIC /audio/v1/... paths to clients. # makes /openapi.json + docs advertise the PUBLIC /audio/v1/... paths to clients.
root_path=config.ROOT_PATH, root_path=config.ROOT_PATH,
...@@ -116,7 +117,7 @@ def require_auth(request: Request) -> auth.Principal: ...@@ -116,7 +117,7 @@ def require_auth(request: Request) -> auth.Principal:
def healthz(): def healthz():
ok, hint = ears.available() ok, hint = ears.available()
return { return {
"service": config.SERVICE, "service": "nech-audio",
"api": "audio", "api": "audio",
"version": config.VERSION, "version": config.VERSION,
"status": "ok", "status": "ok",
......
{ {
"openapi": "3.1.0", "openapi": "3.1.0",
"info": { "info": {
"title": "Douanier \u2014 the `audio` sub-API of the nech.pl platform", "title": "Nech.PL Audio Intelligence API",
"description": "Customs gate over the fleet's audio-intelligence engines. Served publicly at /audio/v1/...; the platform gateway does central auth + metering and injects X-Tenant/X-Scopes. See SRE.md + DEPLOY.md.", "description": "Stem-aware audio analysis \u2014 emotion, features, sample role, loop grading, onsets/tempo, waveform & spectrogram, loudness, naming. The `audio` API of the Nech.PL APIs platform, served at /audio/v1/...; the gateway does central auth + metering (Bearer token).",
"version": "0.1.0", "version": "0.1.0"
"x-engines": "emotion features samples grade onsets waveform analyze loudness spectrum naming separate"
}, },
"paths": { "paths": {
"/healthz": { "/healthz": {
...@@ -720,7 +719,7 @@ ...@@ -720,7 +719,7 @@
"servers": [ "servers": [
{ {
"url": "https://api.nech.pl/audio/v1", "url": "https://api.nech.pl/audio/v1",
"description": "nech.pl platform \u2014 audio sub-API" "description": "Nech.PL APIs gateway (public)"
} }
] ]
} }
\ No newline at end of file
...@@ -27,7 +27,7 @@ def test_healthz_ok(): ...@@ -27,7 +27,7 @@ def test_healthz_ok():
r = client.get("/healthz") r = client.get("/healthz")
assert r.status_code == 200 assert r.status_code == 200
body = r.json() body = r.json()
assert body["service"] == "douanier" and body["api"] == "audio" assert body["service"] == "nech-audio" and body["api"] == "audio"
assert "emotion" in body["engines"] and "separate" in body["engines"] assert "emotion" in body["engines"] and "separate" in body["engines"]
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment