List roles
list_rolesRetrieve database roles and attributes like superuser, login, and replication. Excludes system roles by default; set include_system to true to include them, or target a specific database.
Instructions
List the database roles and their attributes, excluding PostgreSQL's own roles unless include_system is true. Returns a list of objects with name, superuser, create_role, create_db, can_login, replication, bypass_rls, connection_limit, member_of.
Input Schema
| Name | Required | Description | Default |
|---|---|---|---|
| database | No | Optional: target a configured secondary (read-only) database by name; omit for the primary. Call list_databases to see the configured ids. | |
| include_system | No |
Output Schema
| Name | Required | Description | Default |
|---|---|---|---|
| result | Yes |