# JSON Schema Pgaudit

System-wide settings for the pgaudit extension.

## Properties

| Property | Type | Required | Description |
| --- | --- | --- | --- |
| `feature_enabled` | boolean | no | Enable pgaudit extension. When enabled, pgaudit extension will be automatically installed.Otherwise, extension will be uninstalled but auditing configurations will be preserved.<br/><br/>Default: `false`. |
| `log` | array[string] | no | Specifies which classes of statements will be logged by session audit logging. |
| `log_catalog` | boolean | no | Specifies that session logging should be enabled in the case where all relations in a statement are in pg_catalog.<br/><br/>Default: `true`. |
| `log_client` | boolean | no | Specifies whether log messages will be visible to a client process such as psql.<br/><br/>Default: `false`. |
| `log_level` | string | no | Specifies the log level that will be used for log entries.<br/><br/>Allowed values: `debug1`, `debug2`, `debug3`, `debug4`, `debug5`, `info`, `notice`, `warning`, `log`.<br/><br/>Default: `log`. |
| `log_max_string_length` | integer | no | Crop parameters representation and whole statements if they exceed this threshold. A (default) value of -1 disable the truncation.<br/><br/>Min: `-1`. Max: `102400`. Default: `-1`. |
| `log_nested_statements` | boolean | no | This GUC allows to turn off logging nested statements, that is, statements that are executed as part of another ExecutorRun.<br/><br/>Default: `true`. |
| `log_parameter` | boolean | no | Specifies that audit logging should include the parameters that were passed with the statement.<br/><br/>Default: `false`. |
| `log_parameter_max_size` | integer | no | Specifies that parameter values longer than this setting (in bytes) should not be logged, but replaced with <long param suppressed>.<br/><br/>Default: `0`. |
| `log_relation` | boolean | no | Specifies whether session audit logging should create a separate log entry for each relation (TABLE, VIEW, etc.) referenced in a SELECT or DML statement.<br/><br/>Default: `false`. |
| `log_rows` | boolean | no | Default: `false`. |
| `log_statement` | boolean | no | Specifies whether logging will include the statement text and parameters (if enabled).<br/><br/>Default: `true`. |
| `log_statement_once` | boolean | no | Specifies whether logging will include the statement text and parameters with the first log entry for a statement/substatement combination or with every entry.<br/><br/>Default: `false`. |
| `role` | string | no | Specifies the master role to use for object audit logging.<br/><br/>Max length: `64`. |

