Skip to content

spec.server ​

Runtime HTTP server configuration. The only required field is port; the rest tune transport and auth.

yaml
spec:
  server:
    port: 8080
    scheme: https
    debug: false
    auth:
      enabled: true
    authz:
      enabled: true
      mode: custom

Fields ​

FieldTypeRequiredConstraintDescription
portinteger✓1 ≤ port ≤ 65535TCP port the server binds to.
schemestring-URL scheme (http, https). Influences emitted URLs in code.
debugboolean-Enable verbose debug logging in generated code.
authobjectsee AuthAuthentication block (who the caller is).
authzobjectsee AuthzAuthorization block (what the caller may do).

spec.server.auth ​

yaml
spec:
  server:
    auth:
      enabled: true
FieldTypeRequiredDescription
enabledbooleanIf true, the generator wires authentication into the server pipeline; if false or omitted, the server is open.

The schema deliberately keeps auth minimal in v1: it carries the intent (auth on / off), and the concrete mechanism (JWT, OIDC, mTLS, etc.) is the generator's territory. Future minor versions may extend this block with typed sub-configs as patterns stabilise across consumers.

spec.server.authz ​

yaml
spec:
  server:
    authz:
      enabled: true
      mode: deny-all
FieldTypeRequiredDescription
enabledbooleanMaster switch. When true, the generated project scaffolds a user-owned BeforeTool authorization callback. Off by default.
modestringDefault policy until you write custom logic: allow-all (permit everything), deny-all (reject everything), custom (your own code). Defaults to allow-all.

Both fields are optional. When authz is omitted entirely, no callback is scaffolded and the effective mode is allow-all.

auth and authz answer different questions: auth is authentication - establishing who the caller is - while authz is authorization - deciding what that caller is allowed to invoke. The scaffolded BeforeTool callback runs per tool call, so it is the hook where you gate individual tools on the authenticated identity. Enabling one does not enable the other.