feat(admin): show the allowance of place search, address search and routing in the TREK API card

GET /api/admin/service-identity lists places, photon and valhalla, each with
today's allowance read fresh from /v1/quota of its own host (cached for 20
seconds per host) and whether this instance asks it right now: Photon only
beside the public Nominatim, the TREK Valhalla only where the routing choice
comes to it. Photon and Valhalla are asked only with a key and only while
TREK_SERVICES_HOSTS lists them. The last allowance an answer stated is kept
per host for when a host does not answer.

The card lists the three services under each other in the look it had,
a service this instance does not ask dimmed and named as such.
This commit is contained in:
Maurice
2026-10-29 10:44:50 +01:00
committed by Maurice
parent 091ebed8e4
commit bc62eb0d6f
43 changed files with 531 additions and 89 deletions
+4
View File
@@ -144,6 +144,10 @@ const admin: TranslationStrings = {
'admin.trekApi.quota.hint.revoked':
"La clau d'aquesta instal·lació s'ha revocat. Les cerques fan servir la reserva compartida fins que creïs una identitat nova.",
'admin.trekApi.quota.unavailable': 'Ara mateix no es pot llegir la quota.',
'admin.trekApi.quota.service.places': 'Cerca de llocs',
'admin.trekApi.quota.service.photon': 'Cerca d’adreces',
'admin.trekApi.quota.service.valhalla': 'Rutes',
'admin.trekApi.quota.notInUse': 'No s’utilitza en aquesta instància',
'admin.trekApi.quota.envKey': 'La clau ve de TREK_SERVICES_KEY.',
'admin.trekApi.quota.regenerate': 'Identitat nova',
'admin.trekApi.quota.regenerateTitle': 'Vols crear una identitat nova?',