policyDebug
policyDebug(
c,policyName):DebugLogger
Defined in: src/policies/sdk/helpers.ts:47
Get a debug logger pre-namespaced to stoma:policy:{name}.
Returns noopDebugLogger when there is no gateway context
(e.g. outside a gateway pipeline) or when debug is disabled.
This eliminates the repeated getGatewayContext(c)?.debug(...) pattern.
Parameters
Section titled “Parameters”Context
Hono request context.
policyName
Section titled “policyName”string
Policy name used in the namespace.
Returns
Section titled “Returns”A DebugLogger — always callable, never undefined.