Serves what other gerbeur instances read about this one before federated sign-in, at the root paths OpenID Connect fixes, which are the one exception to the API's /api/ rule. remote/gerbeur-instance.ts reads them on the other side.

  • GET /.well-known/openid-configuration — public. Answers the instance's metadata (InstanceMetadata): its endpoints, its name and the protocol's version. Bare JSON, not the API's envelope.
  • GET /.well-known/jwks.json — public. Answers the public keys its tokens are signed with. Bare JSON.

Variables

v
default: Router

Mounted by api/main.ts behind the error, Open Graph and CORS middleware. An APIException thrown by a handler becomes the JSON error response there.

Usage

import * as mod from "api/routes/well-known.ts";