CSENSE001: Missing Documentation
The diagnostic identifier
The diagnostic category
The default severity level
Whether this rule is enabled by default
Description
Publicly accessible APIs should be documented to ensure maintainability and clarity. This diagnostic is reported when a symbol matching the configured visibility level is missing valid XML documentation.Why This Rule Exists
Documentation is essential for:- Helping other developers understand the purpose and usage of your APIs
- Enabling IntelliSense tooltips in IDEs
- Generating API documentation
- Maintaining long-term code quality
How to Fix
Add XML documentation comments to the symbol. At minimum, include a<summary> tag:
Examples
Violation
Fixed
Using inheritdoc
For overridden or implemented members, you can use<inheritdoc /> to inherit documentation from the base member:
Configuration
Visibility Level
Control which members are analyzed based on their accessibility:public- Only public membersprotected- Public and protected members (default)internal- Public, protected, and internal membersprivate- All members including private
Exclude Constants and Enums
You can exclude constants and enum members from documentation requirements:Allow Implicit inheritdoc
When enabled, members that override or implement base members without explicit documentation are treated as having implicit<inheritdoc />:
Related Rules
- CSENSE018 - Missing inheritdoc for override/implementation members