3.39.0
(feat): Add support for logging to the generated SDK.
Users can configure logging by passing a LogConfig to the client builder’s .logging() method.
The LogConfig builder accepts the following properties:
level(LogLevel): The log level to use. Defaults toLogLevel.INFO.logger(ILogger): The logger implementation to use. Defaults toConsoleLogger.silent(boolean): Whether to silence the logger. Defaults totrue.
The LogLevel enum supports the following values:
DEBUGINFOWARNERROR
To provide a custom logger, implement the ILogger interface
with debug, info, warn, and error methods.
HTTP request and response details (method, URL, status code, headers, body) are
logged via a LoggingInterceptor added to the OkHttp client. Sensitive headers
(authorization, x-api-key, cookie, x-csrf-token, etc.) are automatically
redacted in logs.