field-read-only-and-write-only-mutual-exclusiveness
Overview
This rule belongs to the apimatic-preliminary-validation ruleset and states that:
A custom type field/property may be marked as read-only or write-only but not both.
| Property | Value |
|---|---|
| Enabled | Yes |
| Maximum Severity | Error |
| Message | Field is marked as read-only as well as write-only. |
| Code | APIMATICPRE_V518 |
| Type | Validation |
| Rule System | Semantic |
| Broad Category | Global Types/Models |
| Products Impacted | Code Generation, Developer Experience Portal, API Transformer |
| Tags | preliminary checks validation apimatic read-only write-only field custom type model complex model |
Suggested Fixes
- Marking a field as read-only means that it may be sent as part of a response but should not be sent as part of the request.
- Marking a field as write-only means that it may be sent as part of a request but should not be sent as part of the response.